Solved

Got error 0 when trying to run program by exe and no error when run it buy code

Posted on 2016-09-01
2
19 Views
Last Modified: 2016-09-20
When i run program exe and change the general tab text value and click on other tab without saving it show run time error 0.
But if i do same thing when i run program by code it doesn't show any error.
0
Comment
Question by:Nitin Rawat
2 Comments
 
LVL 45

Accepted Solution

by:
Martin Liss earned 500 total points (awarded by participants)
Comment Utility
It would be a big help if you were to zip up and attach your project, but if I have to guess I'd say that you have an error routine at the bottom of some sub or function, but you don't have it preceded by an Exit Sub (or Function). For example if line 7 were missing you'd get error 0 when the sub was run.

Private Sub Example()

    On Error GoTo ErrorRoutine

    ' some code

    Exit Sub

ErrorRoutine:

    MsgBox Err.Number
End Sub

Open in new window

0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now