VBA jumping code

JeffGrant

Well-known Member
Joined
Apr 7, 2021
Messages
516
Office Version
  1. 365
Platform
  1. Windows
Hi all,

I am looking for some feedback please. Periodically, VBA will completely jump a Call to another sub. There is absolutly no reason for this. If I run the code via F8 everything is fine. If I rerun the code, it works.

My issue is that if the Call is missed and I dont know about it, then I will be getting incorrect results.

I am not sure how I can even test for this.

This does not happen all the time, but it does happen frequently enough for me to be concerned about it.

Has anybody else had this problem?

Thanks in advance.
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Hi Alex, the error traping calls another error sub, not a resume next. Thanks for the suggestion.

It is just like vba is completely jumps over that particular Call statement.
cheers
 
Upvote 0
It still sounds like there is an error and it is jumping the line, so either comment out the "On Error" line (unless it is goto 0) or in Tools > Option, change the setting to Break on All Errors.
(Just remember to change it back when you have finished trouble shooting ;))

1655796396121.png
 
Upvote 0

Forum statistics

Threads
1,215,052
Messages
6,122,878
Members
449,097
Latest member
dbomb1414

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