Control.UseWaitCursor Control.UseWaitCursor Control.UseWaitCursor Control.UseWaitCursor Property

定義

取得或設定值,指出是否將等待游標用於目前控制項和所有子控制項。Gets or sets a value indicating whether to use the wait cursor for the current control and all child controls.

public:
 property bool UseWaitCursor { bool get(); void set(bool value); };
[System.ComponentModel.Browsable(true)]
public bool UseWaitCursor { get; set; }
member this.UseWaitCursor : bool with get, set
Public Property UseWaitCursor As Boolean

屬性值

true 表示將等待游標用於目前控制項和所有子控制項,否則為 falsetrue to use the wait cursor for the current control and all child controls; otherwise, false. 預設為 falseThe default is false.

備註

每當您執行的作業採用可觀的時間,請使用等待游標。Use a wait cursor whenever you perform an operation that takes a noticeable amount of time. 不過請注意,封鎖 UI 執行緒的作業也會封鎖資料指標變更。However, note that operations that block the UI thread will also block a cursor change. 因此,在另一個執行緒中執行耗時的作業時,應該只使用這個屬性。Therefore, this property should only be used when performing time-consuming operations in another thread. 若要變更資料指標全域和立即,請參閱Current屬性。To change the cursor globally and immediately, see the Current property.

適用於