MESCIUS SPREAD for Windows Forms 15.0J
AcceptsTabChar プロパティ (GcTextBoxCellType)
使用例 

文字列をコピー、切り取り、および貼り付けるときのTab文字の処理方法を示す値を取得または設定します。
構文
'宣言
 
Public Property AcceptsTabChar As TabCharMode
public TabCharMode AcceptsTabChar {get; set;}

プロパティ値

文字列をコピー、切り取り、および貼り付けるときの CrLf 文字の処理モードを示す TabCharMode 列挙体。

既定値は TabCharMode.NoControl です。
例外
例外解説
System.ComponentModel.InvalidEnumArgumentException指定された項目が有効なTabCharModeではありません。
解説
このプロパティはセルが編集モードのときにのみ効果があります。
使用例
次のサンプルコードは、AcceptsTabChar プロパティを使用します。
GrapeCity.Win.Spread.InputMan.CellType.GcDateTimeCellType datecell = new GrapeCity.Win.Spread.InputMan.CellType.GcDateTimeCellType();
datecell.AcceptsCrLf = GrapeCity.Win.Spread.InputMan.CellType.CrLfMode.Cut;
fpSpread1.Sheets[0].Cells[0, 0].CellType = datecell;

GrapeCity.Win.Spread.InputMan.CellType.GcTextBoxCellType textcell = new GrapeCity.Win.Spread.InputMan.CellType.GcTextBoxCellType();
textcell.AcceptsCrLf = GrapeCity.Win.Spread.InputMan.CellType.CrLfMode.Cut;
textcell.AcceptsTabChar = GrapeCity.Win.Spread.InputMan.CellType.TabCharMode.NoControl;
textcell.AllowSpace = GrapeCity.Win.Spread.InputMan.CellType.AllowSpace.Both;
fpSpread1.Sheets[0].Cells[1, 1].CellType = textcell;
Dim datecell As New GrapeCity.Win.Spread.InputMan.CellType.GcDateTimeCellType()
datecell.AcceptsCrLf = GrapeCity.Win.Spread.InputMan.CellType.CrLfMode.Cut
fpSpread1.Sheets(0).Cells(0, 0).CellType = datecell

Dim textcell As New GrapeCity.Win.Spread.InputMan.CellType.GcTextBoxCellType()
textcell.AcceptsCrLf = GrapeCity.Win.Spread.InputMan.CellType.CrLfMode.Cut
textcell.AcceptsTabChar = GrapeCity.Win.Spread.InputMan.CellType.TabCharMode.NoControl
textcell.AllowSpace = GrapeCity.Win.Spread.InputMan.CellType.AllowSpace.Both
fpSpread1.Sheets(0).Cells(1, 1).CellType = textcell
参照

GcTextBoxCellType クラス
GcTextBoxCellType メンバ

 

 


© MESCIUS inc. All rights reserved.