protected void btnMakeCellReadOnly_Click(object sender, EventArgs e)
{
// ExStart:MakeCellReadOnly
// Accessing the first worksheet that is currently active
GridWorksheet sheet = GridWeb1.WorkSheets[GridWeb1.ActiveSheetIndex];
// Set the 1st cell (A1) read only
sheet.SetIsReadonly(sheet.Cells["A1"], true);
// ExEnd:MakeCellReadOnly
}
}