Translates the specified keyCode, if a corresponding accelerator exists.
[Visual Basic .NET] Public Function TranslateAcceleratorKey ( _ ByVal keyCode As Integer _ ) As Boolean
[C#] public bool TranslateAcceleratorKey ( int keyCode );
[C++]
HRESULT TranslateAcceleratorKey(
long keyCode,
VARIANT_BOOL* bHandled
);
[C++]Parameters
keyCode [in] keyCode is a parameter of type long bHandled [out, retval] bHandled is a parameter of type VARIANT_BOOL
Product Availability
Available with ArcGIS Engine.
Description
Returns whether the specified keyCode is a supported accelerator (shortcut) or access key, defined in an ICommand::Caption property of a Command in the CommandPool. To translate an accelerator key, the ICommand::OnClick method must be called.
For example, a 'Close' command with the caption "&Close\tAlt+F4" has the 'ALT+F4' key combination as its shortcut key, and the 'C' key as its access key.
When using the TranslateAcceleratorKey pass the keyCode of the none system key only. For example, if the accelerator is "Ctrl+K", pass the keyCode for "K" to TranslateAcceleratorKey. The system will automatically check for the system key "Ctrl".