protected void GridWeb1_CustomCommand(object sender, string command)
{
// Identifying a specific button by checking its command
if (command.Equals("MyButton"))
{
// Accessing the cells collection of the worksheet that is currently active
GridWorksheet sheet = GridWeb1.WorkSheets[GridWeb1.ActiveSheetIndex];
// Putting value to "A1" cell
sheet.Cells["A1"].PutValue("My Custom Command Button is Clicked.");
// Set first column width to make the text visible
sheet.Cells.SetColumnWidth(0, 30);
}
}
// ExEnd:HandleCustomCommandEvent