From: JOHABE on 29 Oct 2009 17:20 Hello there, I'm writing a macro that displays the KeyBindings associated with commands in my custom commandbarcontrols. I can get the keybindings from autotexts, styles, and macros, beacuse i can retrieve their identifying names from the commandbarcontrol object: from the Parameter property and the OnAction property. However, when the control contains a built-in word command (say File Open), I can only retrieve the command-ID (23 for File Open) from the control. This does not help me in finding the keybindings associated with that command, because the KeysBoundTo command requires a command NAME ("FileOpen"), not an ID. How can I solve this? Is there a way to associate ID's with command names? Or another solution maybe? Any help will be appreciated! -- A professional template builder
From: Pesach Shelnitz on 30 Oct 2009 03:50 Hi, I don't know a way to do this programmatically, but you can find all the command names and the associated keyboard shortcuts in the UI. In Word 2007, click the Office button, click Word Options, click Customize, click the Customize button for keyboard shortcuts, and then in the Categories list, click All Commands. In Word 2003 and earlier version, on the Tools menu, click Customize, click Keyboard, and then in the Categories list, click All Commands. -- Hope this helps, Pesach Shelnitz "JOHABE" wrote: > Hello there, > > I'm writing a macro that displays the KeyBindings associated with commands > in my custom commandbarcontrols. > > I can get the keybindings from autotexts, styles, and macros, beacuse i can > retrieve their identifying names from the commandbarcontrol object: > from the Parameter property and the OnAction property. > > However, when the control contains a built-in word command (say File Open), > I can only retrieve the command-ID (23 for File Open) from the control. > > This does not help me in finding the keybindings associated with that > command, because the KeysBoundTo command requires a command NAME > ("FileOpen"), not an ID. > > How can I solve this? Is there a way to associate ID's with command names? > Or another solution maybe? > Any help will be appreciated! > > -- > A professional template builder
|
Pages: 1 Prev: Convert to PDF Next: Inserting content control in Word 2007 Footer using Word PIA in C# |