Home > Working with SGWorld > Command (ICommand6) > CanExecute
Checks whether a specific TerraExplorer command can be executed.
JavaScript |
|
CanExecute(CommandID, parameter) |
C# |
|
bool CanExecute( int CommandID, object parameter) |
C++ |
|
HRESULT CanExecute( long CommandID, VARIANT parameter, VARIANT_BOOL * bRes ) |
Parameters
CommandID
The ID of the menu command whose status is being checked. See the list of menu commands organized according to TerraExplorer Ribbon tabs.
parameter
The command parameters.
Return Value
bres
A Boolean that indicates whether the command can be executed or not.
Exceptions
See: HRESULT Return Values for a list of possible values returned by the HRESULT.