How to show DropDown with CRUD action list instead of showing individual items in toolbar?How to show DropDown in toolbar with CRUD operations instead of rendering toolbar icons.
This Knowledge Base explains the way, to place the dropdown by customizing the toolbar and to perform CRUD operations based on the selected item from the dropdown instead of showing individual items in toolbar.instead of rendering the default toolbar icons.
HTML
JS
Razor
C#
ASPX
Using the create event of dropdown, we can disable some of the items like update, cancel at the initial load of dropdown as like it is done in the default toolbar icons of grid at the initial rendering In the change event of dropdown, based on args.text value perform the CRUD operations with using some CRUD public methods of grid. Example: In the change event of dropdown, for adding the a new row for grid it is enough to call the addRecord method of grid when args.text contains value is “add”.
Figure 1: Aadding the Data/Rows to the grid using dropdown. Figure 2: Shown alert message when editing the grid without selecting any rows. Figure 3: Normal Editing in grid and also disables the remaining items in dropdown which are not necessary to show. |
This page will automatically be redirected to the sign-in page in 10 seconds.