DHTMLX Docs & Samples Explorer

Index
dhtmlxtree
Error Handling

## Error Handling

Some exceptions in dhtmlxTree can be captured and processed.

        function myErrorHandler(type, desc, erData){
                alert(erData[0].status)
        }
        dhtmlxError.catchError("ALL",myErrorHandler);

The handler gets the following parameters:

- type - supported error types (“All” or “Load XML”);
- desc - error description (hardcoded in code);
- erData - error related array of objects ([0] - response object).