文字数・バイト数単位で入力制限をする方法
対象製品
El Tabelle MultiRow 4.0J
詳細
入力文字数または入力バイト数を制限するには、文字列型セルの MaxLength プロパティ
および LengthAsByte プロパティを使用します。
[Visual Basic]
[C#]
および LengthAsByte プロパティを使用します。
[Visual Basic]
Dim objTextEditor As New GrapeCity.Win.ElTabelle.Editors.TextEditor
'最大文字数・バイト数を指定する
objTextEditor.MaxLength = 5
'True のときバイト単位、False のとき文字単位
objTextEditor.LengthAsByte = True
MultiRowSheet1(0, 0, 0).Editor = objTextEditor
'最大文字数・バイト数を指定する
objTextEditor.MaxLength = 5
'True のときバイト単位、False のとき文字単位
objTextEditor.LengthAsByte = True
MultiRowSheet1(0, 0, 0).Editor = objTextEditor
[C#]
GrapeCity.Win.ElTabelle.Editors.TextEditor objTextEditor =
new GrapeCity.Win.ElTabelle.Editors.TextEditor();
//最大文字数・バイト数を指定する
objTextEditor.MaxLength = 5;
//true のときバイト単位、false のとき文字単位
objTextEditor.LengthAsByte = true;
multiRowSheet1[0, 0, 0].Editor = objTextEditor;
new GrapeCity.Win.ElTabelle.Editors.TextEditor();
//最大文字数・バイト数を指定する
objTextEditor.MaxLength = 5;
//true のときバイト単位、false のとき文字単位
objTextEditor.LengthAsByte = true;
multiRowSheet1[0, 0, 0].Editor = objTextEditor;
キーワード
HowTo
この文書は、以前は次のFAQ IDで公開されていました : 9531