energywatch
New Member
- Joined
- Feb 4, 2014
- Messages
- 6
Hi, I'm new to the forum. Thank you in advance for your help and sorry if I do not follow protocol (I am still learning).
I am trying to build some macros in my own workbook to be able to improve efficiency to a protected workbook that can not be changed directly. I would like to:
- While in 'macros.xlsm' file
- Use 'Shift+B' to go to workbookM.xlsm
- Run "MacroB"
So far I have used:
.OnKey Key:="^+B", Procedure:="MacroB" (doesnt work)
and
Application.Run "workbookM.xlsm!MacroB" (doesnt work)
So far the keystroke gives me an error "Cannot run the macro "C:___". The macro may not be available in this workbook or all macros may be disabled."
When I run through the VBA using F8 I successfully get to MacroB. But, it breaks when the macro starts to refer to sheets by name. Do I need to activate workbookM? If so how?
Thank you for all of your help,
ew
I am trying to build some macros in my own workbook to be able to improve efficiency to a protected workbook that can not be changed directly. I would like to:
- While in 'macros.xlsm' file
- Use 'Shift+B' to go to workbookM.xlsm
- Run "MacroB"
So far I have used:
.OnKey Key:="^+B", Procedure:="MacroB" (doesnt work)
and
Application.Run "workbookM.xlsm!MacroB" (doesnt work)
So far the keystroke gives me an error "Cannot run the macro "C:___". The macro may not be available in this workbook or all macros may be disabled."
When I run through the VBA using F8 I successfully get to MacroB. But, it breaks when the macro starts to refer to sheets by name. Do I need to activate workbookM? If so how?
Thank you for all of your help,
ew