Local Function referenced with *.xlm! prefix

pizzaboy

Board Regular
Joined
Mar 23, 2015
Messages
56
Office Version
  1. 2019
Platform
  1. Windows
Under Macros, functions from one of my modules has the workbook and module name prefixed to it. Wouldn't be much of a concern, but it won't let me assign a shortcut key to it as a result.

How do I get the macros to name the functions as initially set?


Any help would be greatly appreciated.

Cheers
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
I usually run into issues like that when there are duplicates floating around.

Make sure the name of the Sub isn't replicated anywhere else within your modules.
 
Upvote 0
No duplicates hotabae

I was originally copying modules over from another project which may have caused the initial conflict, however they are pointing to the right module functions (the prefix points to the right place!).
 
Upvote 0
The reason Excel is adding that prefix is because it needs extra clarification as to Which version of the macro you wish to use.

I was originally copying modules over from another project

If you have the original project open still, it would treat the new ones as "duplicates" and need to specify the ones from THIS project.​
-Another Cause can be having a duplicate macro/sub that exists in your "Personal" workbook

If you are running a macro via Sheet1, but the code is stored in sheet2's code, it would do something like that.

If you have a macro that shares the same name as a module or userForm, it would cause this issue.

If the source of your macro is a module in another workbook, it would appear like this.​

Outside of these cases, there may be other causes, but I'm not familiar enough with them to denote them at this time.

Hope this helps!
 
Upvote 0
Thanks hotabae

I've closed all other workbooks. No more conflicting names (workbooks/sheets or module/functions), unfortunately the issue still stands - can't assign a shortcut to a macro which has a hard referenced assignment...
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,175
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top