onLoadXmlError issue - need an example


We are using DHTMLX 4.0 version.
I am creating a treegrid. And I am using dynamic loading feature in treegrid. I am loading my grid using the following methods:


As per the documentation, I have replaced dhtmlxError.catchError with windows.dhx4.attachEvent("onLoadXMLError", function);

I am trying to use the above in the following way:

 window.dhx4.attachEvent("onLoadXMLError", function (request){ 
	var msg =  request.responseText ? request.responseText : "Error getting data";
	//msg = (msg != null) ? msg.substring(8, msg.length) : "";
} );

But what I get in alert message is “Incorrect XML”. I am not able to get the XMLHttpRequest object as given in the APIs.

Could you please let me know where I am going wrong?

Please, try to use the second attibute of the onLoadXMLError event:

window.dhx4.attachEvent(“onLoadXMLError”, function (request,obj){