Excel macro stalls when executing from keyboard

medic5678

Board Regular
Joined
Nov 13, 2018
Messages
67
Hi everyone! I have written a macro which works perfectly except it hangs when I execute it from the keyboard. In this macro, I open an excel file and update it, then save it and close it. When I start it from the keyboard, it opens the file to update, then simply quits. The active window and worksheet is the file I opened. Any idea why it should behave differently based on how you start it? I have just changed the hotkey combination from ctrl +shift + W to ctrl + g. Works fine from the keyboard now. Anyone know what's going on with this? Thanks!
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
If you open a file while keeping the Shift key pressed (as to obtain W) then the new file opens but is macro are disabled. This explain why using "g" (low case) works

Bye
 
Upvote 0
I never though about the shift key interacting with the letter you are pressing. Funny that excel would steer you that way when assigning hotkeys to macros.
 
Upvote 0

Forum statistics

Threads
1,214,649
Messages
6,120,733
Members
448,987
Latest member
marion_davis

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