Skip to main content

ASPxClientTreeList.PerformCustomCallback(arg) Method

Obsolete. Sends a callback to the server and generates the server-side ASPxTreeList.CustomCallback event, passing it the specified argument.

Declaration

PerformCustomCallback(
    arg: string
): void

Parameters

Name Type Description
arg string

A string value that represents any information that needs to be sent to the server-side ASPxTreeList.CustomCallback event.

Remarks

Use the PerformCustomCallback method if you need to asynchronously go to the server and perform some server-side processing using AJAX-based callback technology. You can pass the required information which can be collected on the client side as a string of arguments via the arg parameter.

The PerformCustomCallback method posts back to the server using the callback technology and generates a server-side ASPxTreeList.CustomCallback event. The method’s arg argument is passed to the ASPxTreeList.CustomCallback event’s handler as the TreeListCustomCallbackEventArgs.Argument property.

Example

This example shows how to delete selected nodes.

The image below shows the result:

exDeleteSelectedNodes

To learn more, see Adding and Deleting Nodes.

using DevExpress.Web.ASPxTreeList;

protected void Page_Load(object sender, EventArgs e) {
    ASPxTreeList1.SettingsEditing.AllowRecursiveDelete = true;
}
protected void ASPxTreeList1_CustomCallback(object sender,
TreeListCustomCallbackEventArgs e) {
    foreach (TreeListNode node in ASPxTreeList1.GetSelectedNodes())
        ASPxTreeList1.DeleteNode(node.Key);
    ASPxTreeList1.DataBind();
}
See Also