![]() |
Macro name issue
Hi all,
I keep most of my macros in individual modules in my personal workbook. When I hit Alt-F8 to run a macro, some of the names are doubled, for example PERSONAL.XLS!Generic_Sort1 while others are listed as PERSONAL.XLS!GetAverageNum.GetAverageNum I thought it was only the macros in their own separate modules, but some of the "one macro modules" are also listed like this. This affects the way I call macros from other modules as I have to list the name twice with a period "." in-between. Any idea why some macros are like this? Thx, JP |
Macro name issue
Sounds like you are naming your code modules with the same name as the
subroutine. So in module 'GetAverageNum', you have a subroutine or function also named 'GetAverageNum'? Try naming your standard code module something like 'modMacros' or 'modMathFunctions', then put all of your macros in this single module. -- Regards, Bill Renaud |
Macro name issue
Just to add to Bill's response...
If you don't change the names of the modules, you'll find that excel can have trouble finding the function. I guess my point is that I want to make Bill's advice mandatory. JP wrote: Hi all, I keep most of my macros in individual modules in my personal workbook. When I hit Alt-F8 to run a macro, some of the names are doubled, for example PERSONAL.XLS!Generic_Sort1 while others are listed as PERSONAL.XLS!GetAverageNum.GetAverageNum I thought it was only the macros in their own separate modules, but some of the "one macro modules" are also listed like this. This affects the way I call macros from other modules as I have to list the name twice with a period "." in-between. Any idea why some macros are like this? Thx, JP -- Dave Peterson |
Macro name issue
I'll try it out, thanks guys
--JP On Oct 30, 8:23 pm, Dave Peterson wrote: Just to add to Bill's response... If you don't change the names of the modules, you'll find that excel can have trouble finding the function. I guess my point is that I want to make Bill's advice mandatory. JP wrote: Hi all, I keep most of my macros in individual modules in my personal workbook. When I hit Alt-F8 to run a macro, some of the names are doubled, for example PERSONAL.XLS!Generic_Sort1 while others are listed as PERSONAL.XLS!GetAverageNum.GetAverageNum I thought it was only the macros in their own separate modules, but some of the "one macro modules" are also listed like this. This affects the way I call macros from other modules as I have to list the name twice with a period "." in-between. Any idea why some macros are like this? Thx, JP -- Dave Peterson- Hide quoted text - - Show quoted text - |
All times are GMT +1. The time now is 03:11 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com