hercule_p2001
New member
- Joined
- Aug 8, 2011
- Messages
- 8
- Reaction score
- 0
- Points
- 0
I use many macros to ease my work and assign short-cut keys to them. I'll explain my problem with an example:
Say I have a 2 workbooks - A and B.
Wkbk A has a macro to do a certain task and I assign it a key Ctrl+g.
Wkbk B also has a macro to do some other task with the same shortcut key of Ctrl+g.
If the workbooks are opened individually one at a time, there is no problem with the macros. BUT if both workbooks are open then even if the active workbook is A, on pressing Ctrl+g, I get an error of subscript out of range and debugging points to a line in the macro of workbook B. Why? What can be done so that the macro in active workbook is the default macro to be played.
Thanks.
Say I have a 2 workbooks - A and B.
Wkbk A has a macro to do a certain task and I assign it a key Ctrl+g.
Wkbk B also has a macro to do some other task with the same shortcut key of Ctrl+g.
If the workbooks are opened individually one at a time, there is no problem with the macros. BUT if both workbooks are open then even if the active workbook is A, on pressing Ctrl+g, I get an error of subscript out of range and debugging points to a line in the macro of workbook B. Why? What can be done so that the macro in active workbook is the default macro to be played.
Thanks.