Partager via


USDTab.CloseControlCanExecute(Object, CanExecuteRoutedEventArgs) Method

Definition

Internal binding function used for XAML declarative actions.

public:
 void CloseControlCanExecute(System::Object ^ sender, System::Windows::Input::CanExecuteRoutedEventArgs ^ e);
public void CloseControlCanExecute (object sender, System.Windows.Input.CanExecuteRoutedEventArgs e);
member this.CloseControlCanExecute : obj * System.Windows.Input.CanExecuteRoutedEventArgs -> unit
Public Sub CloseControlCanExecute (sender As Object, e As CanExecuteRoutedEventArgs)

Parameters

sender
Object

Specifies the control that the action is for.

e
CanExecuteRoutedEventArgs

Specifies the event arguments.

Remarks

The control bindings in your XAML should appear as follows:

<Control.CommandBindings>

<CommandBinding Command = “usd:ActionCommands.CloseControl”
                CanExecute=”CloseControlCanExecute”
                Executed=”CloseControlExecuted” />
</Control.CommandBindings>

A button that uses these bindings should be declared as follows:

<Button Command=”usd:ActionCommands.CloseControl” CommandParameter=”” />

Applies to