TextBox.SelectionStart 屬性

定義

取得或設定文字框中選取文字的開始位置。 當 SelectionLength 為 0 (沒有選取的文字) 時,SelectionStart 屬性會對應至游標位置。

public:
 property int SelectionStart { int get(); void set(int value); };
int SelectionStart();

void SelectionStart(int value);
public int SelectionStart { get; set; }
var int32 = textBox.selectionStart;
textBox.selectionStart = int32;
Public Property SelectionStart As Integer
<TextBox SelectionStart="int"/>

屬性值

Int32

int

目前選取範圍或目前游標位置的起始位置。

適用於