Runaway macro

bbower01

New Member
Joined
Aug 28, 2019
Messages
3
I have a macro running that seems to have run away and will not stop without control alt delete. Also ESC or CTRL-BREAK also don't work. IT's so weird. Sometime I will allow it to run over night and the next day it will be done and other times it will still be running. There is no rhyme or reason for this. HELP please.
 

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
51,140
Office Version
365
Platform
Windows
Welcome to the Board!

It is extremely hard to diagnose what the problem might be without seeing your code (and possibly some sample data).
Note that if your code has some loops that it never exits, you can add a maximum loop counter and have it exit when it hits that number.
 

bbower01

New Member
Joined
Aug 28, 2019
Messages
3
It’s supposed to copy a line and paste it somewhere else when it sees a true. I have the true flash red. I see the true but no copies are pasted.
 

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
51,140
Office Version
365
Platform
Windows
Like I said, without seeing the code, it is extremely difficult to help you. Can you please post your code? We may be able to spot some obvious flaws in it.
 

bbower01

New Member
Joined
Aug 28, 2019
Messages
3
Thx. Your response triggered an idea. I figured it out. Under error checking options. Enable iterative calc was set to high. Thx again
 

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
51,140
Office Version
365
Platform
Windows
You are welcome.
I am glad you were able to figure it out.
 

Eric W

MrExcel MVP
Joined
Aug 18, 2015
Messages
8,794
You can also add a DoEvents line in your loop. That should allow the Control-Break to work for you. Take it out when you're done debugging since it slows down the macro.
 

Forum statistics

Threads
1,078,138
Messages
5,338,476
Members
399,234
Latest member
WaddoAU

Some videos you may like

This Week's Hot Topics

Top