简体   繁体   中英

Excel on exit and macro run: 'Code execution has been interupted'

I am getting a 'Code execution has been interrupted' message on exit from excel intermittently of late. And its frequency is increasing. End allows me to leave excel, but once I get the message, my machine must be rebooted to allow for excel to open and run macros again. This intermittent message does come up with basic excel usage at exit, and is not limited to excel sessions following VBA macros use. Has anyone seen this or have a solution. It is getting very annoying.

I have came across this issue few times during the development of one complex Excel VBA app. Sometimes Excel started to break VBA object quite randomly. And the only remedy was to reboot machine. After reboot, Excel usually started to act normally.

Soon I have found out that solution to this issue is to hit CTRL+Break once when macro is NOT running. Maybe this can help to you too.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM