<kendo:grid-toolbarItem>
If a String value is assigned to the toolbar configuration option, it will be treated as a single string template for the whole grid Toolbar, and the string value will be passed as an argument to a kendo.template() function.If a Function value is assigned (it may be a kendo.template() function call or a generic function reference), then the return value of the function will be used to render the Grid Toolbar contents.If an Array value is assigned, it will be treated as the list of commands displayed in the grid's Toolbar. Commands can be custom or built-in ("cancel", "create", "save", "excel", "pdf").The "cancel" built-in command reverts any data changes done by the end user.The "create" command adds an empty data item to the grid.The "save" command persists any data changes done by the end user. When executed fires saveChanges grid event.The "excel" command exports the grid data in MS Excel format. Fires excelExport grid event.The "pdf" command exports the grid data in PDF format. Fires pdfExport grid event.The "search" command renders the built-in search panel for the grid.The "columns" command renders a global column menu.The "columns" command generates a button to open a global columns menu.The "paste" command enables the user to switch between the "replace" and "insert" modes of the paste functionality. The allowPaste configuration must enabled for the dropdown to appear.
Example
<kendo:grid-toolbar>
<kendo:grid-toolbarItem></kendo:grid-toolbarItem>
</kendo:grid-toolbar>
Configuration Attributes
iconClass java.lang.String
The class for the web font icon of the button that will be rendered in the toolbar.
Example
<kendo:grid-toolbarItem iconClass="iconClass">
</kendo:grid-toolbarItem>
name java.lang.String
The name of the toolbar command. Either a built-in ("cancel", "create", "save", "excel", "pdf") or custom. The name is reflected in one of the CSS classes, which is applied to the button - k-grid-name. This class can be used to obtain reference to the button after Grid initialization and attach click handlers.
Example
<kendo:grid-toolbarItem name="name">
</kendo:grid-toolbarItem>
template java.lang.String
The template which renders the command. By default renders a button.
Example
<kendo:grid-toolbarItem template="template">
</kendo:grid-toolbarItem>
text java.lang.String
The text displayed by the command button. If not set the name option would be used as the button text instead.
Example
<kendo:grid-toolbarItem text="text">
</kendo:grid-toolbarItem>
Event Attributes
template String
The template which renders the command. By default renders a button.
Example
<kendo:grid-toolbarItem template="handle_template">
</kendo:grid-toolbarItem>
<script>
function handle_template(e) {
// Code to handle the template event.
}
</script>
Event Tags
kendo:grid-toolbarItem-template
The template which renders the command. By default renders a button.
Example
<kendo:grid-toolbarItem>
<kendo:grid-toolbarItem-template>
<script>
function(e) {
// Code to handle the template event.
}
</script>
</kendo:grid-toolbarItem-template>
</kendo:grid-toolbarItem>