BoldDeskWe are launching BoldDesk on Product Hunt soon. Learn more & follow us.
Hi Aun,
Thanks for using Syncfusion products.
Query: “we want to add edit/delete icons instead of the "Edit" text”
We can place icons in command buttons instead of text as follows. Please refer the below code snippet.
@(Html.EJ().Grid<object>("ExportGrid") . . . . .Columns(col => {
. . . . col.HeaderText("Actions").IsUnbound(true).Commands(commands => { commands.Type(UnboundType.Edit).ButtonOptions(new ButtonProperties() { ContentType = ContentType.ImageOnly, PrefixIcon = "e-edit" }).Add(); commands.Type(UnboundType.Delete).ButtonOptions(new ButtonProperties() { ContentType = ContentType.ImageOnly, PrefixIcon = "e-delete" }).Add(); commands.Type(UnboundType.Save).ButtonOptions(new ButtonProperties() { ContentType = ContentType.ImageOnly, PrefixIcon = "e-save" }).Add(); commands.Type(UnboundType.Cancel).ButtonOptions(new ButtonProperties() { ContentType = ContentType.ImageOnly, PrefixIcon = "e-cancel" }).Add(); }).Width(75).Add(); }) . . . . ) |
To place the icons in buttons, set the ContentType property of ButtonProperties as ContentType.ImageOnly and provide the icon class in the PrefixIcon as shown above.
For your kind information, this option is included in our latest Volume 4, 2014 Service pack 1 (v12.4.0.30). If we didn’t used v12.4.0.30 then we suggest you to upgrade to our latest version which is available in the below link.
Please let us know if you have any queries.
Regards,
Madhu Sudhanan. P