共用方式為


ButtonBase.CommandCanExecuteChanged 事件

定義

注意

您必須在專案檔中將 EnablePreviewFeatures 屬性設定為 True,並啟用專案中的預覽功能,才能使用此預覽 API。 如需詳細資訊,請參閱 https://aka.ms/dotnet-preview-features

發生于指派給 Command 屬性之 ICommand 的狀態已變更時 CanExecute(Object)

public:
 virtual event EventHandler ^ CommandCanExecuteChanged;
[System.Runtime.Versioning.RequiresPreviewFeatures]
public event EventHandler? CommandCanExecuteChanged;
public event EventHandler? CommandCanExecuteChanged;
[<System.Runtime.Versioning.RequiresPreviewFeatures>]
member this.CommandCanExecuteChanged : EventHandler 
member this.CommandCanExecuteChanged : EventHandler 
Public Custom Event CommandCanExecuteChanged As EventHandler 

事件類型

屬性

適用於