6
9

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

vba【無限ループの止め方】

Posted at

Alt + Esc

Windows7以降有効。

本来はウィンドウを切り替えるショートカットだが、DoループなどでCtrl + Breakが効かないとき、しばらくAlt + Escを押しっぱなしにしてウィンドウを切り替え続けているとVBEのウィンドウになったタイミングで止まる。

Ctrl + Break

キーボードの入力を受け付ける処理(DoEvents)を入れていれば有効。
MsgBoxを無限表示してしまった際などにもメッセージボックスをフォーカスしてこれを押すと止まる。

6
9
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
9

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?