Solved

VB.NET App runs on some computers and not others.

Posted on 2007-03-20
6
545 Views
Last Modified: 2013-11-07
I have written a VB.net 2005 app.  It installs and runs on some computers but on others it returns the following error message immediately:

WindowsApplication1 has encountered a problem and needs to close. We are sorry for the inconvenience.

This tells me nothing.  Is there a way to find out where the conflict is?  I have Try-Catch statements on everything but it isn't getting that far.
0
Comment
Question by:jamesrbarnes
6 Comments
 
LVL 5

Accepted Solution

by:
jef06 earned 175 total points
ID: 18757405
We need more information, try to log error you can use Log4net very easy to use.

You can try to catch the ThreadException and log the exception, in the Program class.

Here in c#

Application.ThreadException += new ThreadExceptionEventHandler(Application_ThreadException);
void Application_ThreadException(object sender, ThreadExceptionEventArgs e)
        {
            Log.LogError("Application_ThreadException", e.Exception);
        }
0
 
LVL 10

Assisted Solution

by:ericwong27
ericwong27 earned 175 total points
ID: 18757481
Try to run that application with administrator credentials first. Probably due to restricts access on some PC.
0
 
LVL 6

Assisted Solution

by:Jon_Raymond
Jon_Raymond earned 150 total points
ID: 18758265
Did you check the application log?
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:jamesrbarnes
ID: 18763342
Jon Raymond,

I am not familiar with the application log.  Can you tell me what I am looking for?

Jim
0
 
LVL 5

Expert Comment

by:jef06
ID: 18763481
A log help you trace information, to know what is happening in your program. look at http://logging.apache.org/log4net/ and setup that up. Then you will be able to see what is wrong.
0
 
LVL 6

Expert Comment

by:Jon_Raymond
ID: 18764988
On a Windows OS go to administration tools and look for EVENT VIEWER. There are numerous logs there. Check the application log and system log
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an analog clock UserControl seems fairly straight forward.  It is, after all, essentially just a circle with several lines in it!  Two common approaches for rendering an analog clock typically involve either manually calculating points with…
More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Need to grow your business through quality cloud solutions? With everything required to build a cloud platform and solution, you may feel like the distance between you and the cloud is quite long. Help is here. Spend some time learning about the Con…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

943 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

10 Experts available now in Live!

Get 1:1 Help Now