Start a Conversation

Unsolved

This post is more than 5 years old

14758

October 11th, 2017 10:00

excel VBA break execution when there's no break key on keyboard

I'm just noticing that on my laptop (Dell XPS 15z) there's no BREAK key (no dedicated number keypad). I'm running the debugger step-by-step and then when all seems fine, I just let it play out. However, it's running in an infinite loop and now I'm realizing there's no way to stop it without the break key!!!!

Is this a bad joke? I had to reboot the computer; is there a more graceful way??

Thanks.

4 Operator

 • 

14K Posts

October 11th, 2017 14:00

And wow, looking at my Latitude 7480, even though I have dedicated PgUp/PgDn keys (unlike some XPS and Precision models), I have no Break key anywhere....  The only debugger I use is PowerShell ISE though, but it supports other key combinations to trigger this, possibly in recognition of the fact that the Break key is disappearing from some laptop keyboards in an aggravating (to me) quest to make things unnecessarily thin and light -- and I guess cheaper.

4 Operator

 • 

14K Posts

October 11th, 2017 14:00

Is pressing the Break key really the sole mechanism the debugger supports to perform this action?  No alternate key combination or even a GUI button to click?  What about using Task Manager to kill the underlying process?

Short of that and plugging in a USB keyboard, you might be able to find some sort of utility that allows you to define a particular key combination that would send a Break command, though this can of course cause problems if the key combination you choose actually performs another function in some applications.

October 13th, 2017 10:00

Use Fn+Ctrl+B  ... btw, you may need to call DoEvents inside some loops in order to let Excel have the time to monitor that key combination

No Events found!

Top