語言

ListBox.UnselectAll 方法

定義

清除 ListBox.

public:
 void UnselectAll();
public void UnselectAll();
member this.UnselectAll : unit -> unit
Public Sub UnselectAll ()

範例

以下範例展示了如何使用 UnselectAll 此方法取消選取清單框中所有項目。

private void UnselectAll(object sender, RoutedEventArgs e)
{
    lb.UnselectAll();
}
Private Sub UnselectAll(ByVal sender As Object, ByVal e As RoutedEventArgs)
    lb.UnselectAll()
End Sub

適用於