473,386 Members | 2,078 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Module breaks with no breakpoint added

My issue is this. I have a function that checks to see if a field isNull. If it is it prompts a msgbox and lets the user no to enter a valid number. What happens is the user enters the number and they are directed to this line of code in the VBA Module? I have no breakpoint selected anywhere near this line of code. Actually, no breakpoints exist in this entire application. How or why is this stopping at that point? Has anyone else ran into this?

Thanks,
Feb 6 '08 #1
7 16971
Delerna
1,134 Expert 1GB
If we are talking about the same thing then yes I have.

Symptom
The code stops at a line as though there was a breakpoint set even though there isn't one. There is no error message so it didn't stop because of an error and if i click the run button to continue, the program continues on and all is well.

Solution
Can't remember the exact process I took but it was something like this

In code mode I actually set the break point at the line it kept stopping at.
Then a ran the program and it stopped at the breakpoint.
Then I clicked the run button to continue.
After the program finished I went back to code mode and turned the brekpoint back off and saved .

After that the program ran without stopping. ????????


I know that at some stage prior to the problem appearing I had been setting and unsetting brekpoints trying to find some bugs in my code. I guess that somewhere along the line I performed a sequence of events that found a bug in vba itself, where vba finds a breakpoint at run time and stops there, but dosn't find the breakpoint at design time and therefore dosn't display it.

Hope this resolves your problem
Feb 6 '08 #2
NeoPa
32,556 Expert Mod 16PB
I've had this too. My solution was similar.
  1. Open spreadsheet and Alt-F11 to VBA window.
  2. Make a simple change (Delete then re-applying a single character will do - but you must move the cursor off the line in-between).
  3. Close all open code windows.
  4. Compile project.
  5. Alt-F11 back to spreadsheet.
  6. Close & save.
Feb 6 '08 #3
I have similar problem. My solution is as follows:

1. Comment out the line that causes the stop
2. Run the procedure once with the affending line commented out
3. Exit Access
4. Restart Access
5. Uncomment the affending line.
6. Run it once
7. Recompile by clicking on debug-> compile

It works charmingly.

Best, James
Feb 26 '08 #4
NeoPa
32,556 Expert Mod 16PB
Ah, good for you!
You seem to have come across the famous "perfect code - but Access got its knickers in a twist" bug :D
Often seen in declaration type code (Constants etc).
You've found the solution already it seems. well done.
Feb 27 '08 #5
When I observed this, I had just set a few breakpoints and had closed Access. I believe it had crashed on closing.

To fix it, I too commented out the offending line, got off the line, and then went back to it and took the comment mark off.

I then compiled/saved/exited and restarted. Cleared right up.
Nov 26 '10 #6
Four years later and it is still a nightmare! And what a waste of time: All morning trying to understand why, but fortunately, the solution is still the same! :)
Thanks for this post!
ps: vba Excel
Aug 18 '14 #7
NeoPa
32,556 Expert Mod 16PB
Just goes to show - old threads ain't dead while they can still help people out there :-)
Aug 18 '14 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Евгений Косенко | last post by:
Hi! I have several questions about the module datetime. The module has been added to Python 2.3. It seems that its interface is raw and dirty. Who is maintainer of the module? Who may answer...
0
by: Peter Steele | last post by:
So, it's easy enough to build a project usig devenv from the command line. Can this be extended so that a new module can be added to a project from the command line?
5
by: TT (Tom Tempelaere) | last post by:
Hi, Once in a while my application throws an NullReferenceException at startup, however it appears to be occurring in an unknown module. If I debug it and ask to 'break', then there is no source...
0
by: chris.atlee | last post by:
Hi there, I haven't seen this topic pop up in a while, so I thought I'd raise it again... What is the status of the path module/class PEP? Did somebody start writing one, or did it die? I...
3
by: JoelH | last post by:
This is really weird... I'm using Visual Basic 2005 Express I have a form - Form1 - with a control called txtStatusBox I have a module attached to the solution for storing some other code. This...
1
by: aznach | last post by:
Hello! I have a shared hosting account at GrokThis.net and have a problem with the module order of the Python search path. I'd like to use django's svn trunk instead of the...
6
by: ARC | last post by:
This is strange... I set a break point on a form's code module, and then after a bit, shut down the main program file. Now whenever I click the button for the form, it opens the code module, with a...
4
by: JohnR | last post by:
I understand the VS2005 still doesn't support data breakpoints in VB. My question is this.. does anybody know of a 3rd party product that DOES support data breakpoints in VB? As an aside, does...
3
by: Jugdish | last post by:
Why doesn't the following work? $HOME/pkg/__init__.py $HOME/pkg/subpkg/__init__.py $HOME/pkg/subpkg/a.py $HOME/pkg/subpkg/b.py # empty import a
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.