<EjsGrid @ref="GridInstance" TValue="Order" AllowPaging="true" DataSource="@Orders">
<GridEvents CommandClicked="CommandClickHandler" TValue="Order"></GridEvents>
<GridColumns>
<GridColumn HeaderText="Navigation" Width="120">
<GridCommandColumns>
<GridCommandColumn Type="CommandButtonType.None" Title="abc"
ButtonOption="@(new CommandButtonOptions()
{
IconCss = "remove-image-icon-icon-image", Content="customcommand"
})" />
</GridCommandColumns>
</GridColumn>
...
</GridColumns>
</EjsGrid>
@code{
...
public void CommandClickHandler(CommandClickEventArgs<Order> args)
{
//Perform your custom command button click operation here. And also with the value in “args” you can differentiate the buttons, if having multiple custom command buttons.
}
}
|