次のサンプルは
TextCellType を作成します。ユーザーは、このセルを編集することはできませんが、文字列を選択することができます。
public void SetTextCell6()
{
TextCellType textCellType1 = new TextCellType();
//Cell can enter edit status and select the text, but cannot edit text
textCellType1.IsReadOnly = true;
this._gcSpreadGrid1[0, 0].CellType = textCellType1;
}
Public Sub SetTextCell6()
Dim textCellType1 As New TextCellType()
'Cell can enter edit status and select the text, but cannot edit text
textCellType1.IsReadOnly = True
Me._gcSpreadGrid1(0, 0).CellType = textCellType1
End Sub