Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
 
Posts: n/a
Default VBA: syntax to review macro names in a file?

I frequently use code such as
Dim SheetName
For Each SheetName in Sheets
.... to perform repetitive actions on all tabs in a workbook. Is there
a similar way to review all macros in a workbook? For instance: if I
wanted to reset any shortcut keys that may be applied to macros, is
there something akin to

dim Makroname
for each Makroname in Reserved_Word_to_Reference_Macro_List
Application.MacroOptions Macro:="'filename.xls'!" & Makroname,
Description:="", ShortcutKey:=""

Thanks

  #2   Report Post  
Jim Rech
 
Posts: n/a
Default

It's my understanding that the shortcut keys assigned to VB macros through
the Excel Macros dialog are only 'seeable' through that dialog and by
exporting (File, Export in the VBE) the code of the VB module. For instance
a sub named MySub to which I had assigned the shortcut "a" had this
'attribute' in the export:

Attribute MySub.VB_ProcData.VB_Invoke_Func = "a\n14"

I don't know what the \n14 means.

The MacroOptions method only seems useful for assigning shortcuts, etc., not
finding them.

And, of course, any shortcuts assigned with OnKey will not show up anywhere.

--
Jim
wrote in message
oups.com...
|I frequently use code such as
| Dim SheetName
| For Each SheetName in Sheets
| ... to perform repetitive actions on all tabs in a workbook. Is there
| a similar way to review all macros in a workbook? For instance: if I
| wanted to reset any shortcut keys that may be applied to macros, is
| there something akin to
|
| dim Makroname
| for each Makroname in Reserved_Word_to_Reference_Macro_List
| Application.MacroOptions Macro:="'filename.xls'!" & Makroname,
| Description:="", ShortcutKey:=""
|
| Thanks
|


  #3   Report Post  
 
Posts: n/a
Default

Thanks, Jim, I'll read up on attributes.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Opening a file in a macro (network) David P. Excel Discussion (Misc queries) 3 June 8th 05 12:35 AM
Macro to save a file as a PDF ynissel Excel Discussion (Misc queries) 8 May 25th 05 10:46 PM
How do I create a macro, that references another excel file ??? Aries Excel Worksheet Functions 1 May 25th 05 11:37 AM
macro to save file automaticaly? david Excel Discussion (Misc queries) 1 May 6th 05 05:21 PM
How to stop getting the file save box when running a macro Pank Mehta Excel Discussion (Misc queries) 1 March 29th 05 04:05 PM


All times are GMT +1. The time now is 05:20 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"