Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I assigned Ctrl-Shift-Z to the macro below. When I execute the macro via
Tools | Macro | Macros... | Run, everything works fine. But if I execute the macro via the keyboard shortcut, the macro inexplicably stops right after line 7. Has anyone else run into this problem and/or can explain why it happens? Please note that "Rates.xls" is open prior to running the macro. Any help would be greatly appreciated. Thanks. 1 - Sub CleanUp() 2 - Application.ScreenUpdating = False 3 - Application.Calculation = xlCalculationAutomatic 4 - fname = ActiveWorkbook.Name 5 - pname = ActiveWorkbook.FullName 6 - spath = Left(pname, Len(pname) - Len(fname)) 7 - Workbooks.Open Filename:=spath & "Taxes.xls" 8 - Workbooks("Rates.xls").Activate 9 - ActiveSheet.Rows("1:5").Delete Shift:=xlUp 10 - ActiveSheet.Rows("2:2").Delete Shift:=xlUp 11 - more code... 55 - End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Edit Menu Keyboard Shortcut Problem | Excel Discussion (Misc queries) | |||
keyboard shortcut for a macro | Excel Worksheet Functions | |||
Unassign Macro Keyboard Shortcut? | Excel Programming | |||
Excel 2007 Date Keyboard Shortcut problem | Excel Discussion (Misc queries) | |||
Keyboard Shortcut in Macro | Excel Discussion (Misc queries) |