Skip to main content
All docs

ASPxClientTreeListKeyboardEventArgs Class

Contains data for ASPxTreeList client-side keyboard events.


declare class ASPxClientTreeListKeyboardEventArgs extends ASPxClientGridKeyboardEventArgsBase


An ASPxClientTreeListKeyboardEventArgs object contains information on the pressed key (the keyCode and htmlEvent properties). You can also use the isAltPressed, isCtrlPressed, and isShiftPressed object properties that specify whether a user presses the corresponding modifier keys.

In the example below, ASPxTreeList allows users to press the custom Ctrl+X shortcut (the X key’s integer code is 88) to export its data to a PDF document.

var xKeyCode = 88;

function onKeyDown(s, e) {
    if (e.isCtrlPressed && e.keyCode == xKeyCode) {
<dx:ASPxTreeList ID="treeList" runat="server" ...>
    <SettingsExport EnableClientSideExportAPI="true" />
    <ClientSideEvents KeyDown="onKeyDown" />
        <dx:TreeListDataColumn FieldName="DepartmentName" Caption="Department" />


See Also