Quantcast
Viewing all articles
Browse latest Browse all 7205

GridView - How to use Bootstrap Glyphicons as Command Buttons

This example is based on the approach illustrated in the How to emulate the Command Column with a data column DataItemTemplate example.
It illustrates how to define custom HTML elements with specific class names inside a column's DataItemTemplate in order to apply a specific appearance (such as Bootstrap Glyphicon):
- Specify a custom column's content (DataItemTemplate) via the MVCxGridViewColumn.SetDataItemTemplateContent method.
- Define the target expected HTML content inside it.
- Attach the client-side "click" event handler to the corresponding HTML elements. Use the related row's data (GridViewDataItemTemplateContainer) and client-side ASPxClientGridView API to mimic the built-in Command Buttons behavior.

Viewing all articles
Browse latest Browse all 7205

Trending Articles