Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Not a show stopper, but when I am developing a complex Macro, I will often
record little slices of code and accept the default Macro name (Macro1, Macro2... etc.), then to test it I may assign a keyboard shortcut to it so I can give it a shot on several WS. Later I may want to re-use the shortcut without deleting the original Macro. In other words I need to "unassign" the shortcut to Macro[n], and assign it to Macro[n+x]. It's the old "quick and dirty" game. However when I use what seems logical, namely the Delete key, I get a nasty-gram telling me that the shortcut meeds to be an alpha character. That being said -- I have a hunch there is a way (the Help files being as unhelpful as usual <g). -- Dave Temping with Staffmark in Rock Hill, SC |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dave,
Search the VBA help for the "OnKey" method. For example, if you have a macro assigned to the shortcut CTRL+1, you can use this to clear it Application.OnKey "^1" you can just type it in the Immediate window of the VBE and hit Enter. -- Hope that helps. Vergel Adriano "Dave Birley" wrote: Not a show stopper, but when I am developing a complex Macro, I will often record little slices of code and accept the default Macro name (Macro1, Macro2... etc.), then to test it I may assign a keyboard shortcut to it so I can give it a shot on several WS. Later I may want to re-use the shortcut without deleting the original Macro. In other words I need to "unassign" the shortcut to Macro[n], and assign it to Macro[n+x]. It's the old "quick and dirty" game. However when I use what seems logical, namely the Delete key, I get a nasty-gram telling me that the shortcut meeds to be an alpha character. That being said -- I have a hunch there is a way (the Help files being as unhelpful as usual <g). -- Dave Temping with Staffmark in Rock Hill, SC |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I KNEW there must be a way <g!
-- Dave Temping with Staffmark in Rock Hill, SC "Vergel Adriano" wrote: Dave, Search the VBA help for the "OnKey" method. For example, if you have a macro assigned to the shortcut CTRL+1, you can use this to clear it Application.OnKey "^1" you can just type it in the Immediate window of the VBE and hit Enter. -- Hope that helps. Vergel Adriano "Dave Birley" wrote: Not a show stopper, but when I am developing a complex Macro, I will often record little slices of code and accept the default Macro name (Macro1, Macro2... etc.), then to test it I may assign a keyboard shortcut to it so I can give it a shot on several WS. Later I may want to re-use the shortcut without deleting the original Macro. In other words I need to "unassign" the shortcut to Macro[n], and assign it to Macro[n+x]. It's the old "quick and dirty" game. However when I use what seems logical, namely the Delete key, I get a nasty-gram telling me that the shortcut meeds to be an alpha character. That being said -- I have a hunch there is a way (the Help files being as unhelpful as usual <g). -- Dave Temping with Staffmark in Rock Hill, SC |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
keyboard shortcut for a macro | Excel Worksheet Functions | |||
Keyboard Shortcut in Macro | Excel Discussion (Misc queries) | |||
writting a macro for the sum function so I can use it as a keyboard shortcut | Excel Programming | |||
writting a macro for the sum function so I can use it as a keyboard shortcut | Excel Programming | |||
Find Keyboard shortcut in a macro | Excel Programming |