ASPxClientFileManager.ToolbarUpdating Event

Fires on the client side when the file manager updates the state of toolbar or context menu items.


ToolbarUpdating: ASPxClientEvent<ASPxClientFileManagerToolbarUpdatingEventHandler<ASPxClientFileManager>>

Event Data

The ToolbarUpdating event handler receives an argument of the ASPxClientFileManagerToolbarUpdatingEventArgs type. The following properties provide information specific to this event.

Property Description
activeAreaName Gets the name of the currently active file manager area.


Write the ToolbarUpdating event handler to control the state of custom toolbar and context menu items. You can use the ASPxClientFileManagerToolbarUpdatingEventArgs.activeAreaName event argument property to determine the currently active area.

A particular item can be accessed by its command name using the ASPxClientFileManager.GetToolbarItemByCommandName and ASPxClientFileManager.GetContextMenuItemByCommandName methods, which return a ASPxClientFileManagerToolbarItem object. You can use the object members to control the item availability.


The complete sample is available in the DevExpress online demo File Manager - Custom Toolbar

<dx:ASPxFileManager ID="FileManager" ClientInstanceName="FileManager" runat="server">
     <ClientSideEvents ToolbarUpdating="OnToolbarUpdating" />
               <dx:FileManagerToolbarCustomButton CommandName="Properties">
                    <Image IconID="setup_properties_16x16" />
function OnToolbarUpdating(s, e) {
     var enabled = (e.activeAreaName == "Folders" || FileManager.GetSelectedItems().length > 0) && e.activeAreaName != "None";
See Also