473,396 Members | 1,884 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,396 software developers and data experts.

Unhandled exception

Hi there,

Im experiencing an unhandled exception that seems to be impossible for
me to catch. I am launching an assembly of mine from within another
assembly using the Process object. Once the process finishes it causes an
unhandled exception, even though both host and child process have all thread
exceptions handled.

Unfortunately this is making debugging a complete and utter nightmare as
the application has already terminated by the time the standard unhandled
excaption dialog appears with this info in...

EventType : clr20r3 P1 : <child assembly> P2 : 1.3.2323.22525
P3 : 44648dad
P4 : mscorlib P5 : 2.0.0.0 P6 : 4333ab80 P7 : 11d0 P8 : 27
P9 : system.applicationexception

Any ideas what this is supposed to mean exactly? It has no relevance to
me but if I could just know what the exception is exactly then this could
help, "applicationexception" doesn't help me in the slightest as i have 3
assemblies that derive from said applicationexception that are being used
during this process.

I can only presume that this error could be down to the disposing of an
object by the garbage collector, I cant think of any other reason why code
would remain to be processed after the last line of code has been passed..

Thanks loads in advance if anyone can help me with this.

Nick.
May 12 '06 #1
3 2970
Hi there,

Just to add, I've managed to get rid of the exception by disposing a
specific object before the application exits. The object was only disposing
a mutex so I'm not quite sure how this would cause an exception at garbage
collection time.. Anyway, it's gone now so I guess I shouldn't complain!

Nick.

"NickP" <a@a.com> wrote in message
news:uG**************@TK2MSFTNGP04.phx.gbl...
Hi there,

Im experiencing an unhandled exception that seems to be impossible for
me to catch. I am launching an assembly of mine from within another
assembly using the Process object. Once the process finishes it causes an
unhandled exception, even though both host and child process have all
thread exceptions handled.

Unfortunately this is making debugging a complete and utter nightmare
as the application has already terminated by the time the standard
unhandled excaption dialog appears with this info in...

EventType : clr20r3 P1 : <child assembly> P2 : 1.3.2323.22525
P3 : 44648dad
P4 : mscorlib P5 : 2.0.0.0 P6 : 4333ab80 P7 : 11d0 P8 : 27
P9 : system.applicationexception

Any ideas what this is supposed to mean exactly? It has no relevance
to me but if I could just know what the exception is exactly then this
could help, "applicationexception" doesn't help me in the slightest as i
have 3 assemblies that derive from said applicationexception that are
being used during this process.

I can only presume that this error could be down to the disposing of an
object by the garbage collector, I cant think of any other reason why code
would remain to be processed after the last line of code has been passed..

Thanks loads in advance if anyone can help me with this.

Nick.

May 12 '06 #2
Nick,
You could use the AppDomain object to register a handler for Unhandled
Exceptions in your app, allowing you to see more detail about the
problem you're occuring.
Module Module1

Sub Main()

AddHandler AppDomain.CurrentDomain.UnhandledException,
AddressOf Unhandled

Throw New Exception("Unhandled Exception")

End Sub

Private Sub Unhandled(ByVal sender As Object, ByVal e As
UnhandledExceptionEventArgs)

Console.WriteLine("Unhandled Exception of Type " &
e.ExceptionObject.GetType.ToString)
Console.WriteLine(e.ExceptionObject.ToString)
Console.ReadLine()

End Sub

End Module
john

May 12 '06 #3
Hi John,

Indeed I have been, and also the thread exception. But neither would
catch this exception, I believe it was because the application had already
terminated and it was occuring during garbage collection. All sorted now
though thankfully, cheers for your input.

Nick.

"jayeldee" <ja******@gmail.com> wrote in message
news:11**********************@d71g2000cwd.googlegr oups.com...
Nick,
You could use the AppDomain object to register a handler for Unhandled
Exceptions in your app, allowing you to see more detail about the
problem you're occuring.
Module Module1

Sub Main()

AddHandler AppDomain.CurrentDomain.UnhandledException,
AddressOf Unhandled

Throw New Exception("Unhandled Exception")

End Sub

Private Sub Unhandled(ByVal sender As Object, ByVal e As
UnhandledExceptionEventArgs)

Console.WriteLine("Unhandled Exception of Type " &
e.ExceptionObject.GetType.ToString)
Console.WriteLine(e.ExceptionObject.ToString)
Console.ReadLine()

End Sub

End Module
john

May 15 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Chuck Hartman | last post by:
I have a Windows service that requests web pages from a site using an HttpWebRequest object. When I try to request a page from an ASP.NET 2 site, I get a WebException with message "The remote...
5
by: Dave Stewart | last post by:
I recently wrote my first Vb.net application, or at least my first complex app since moving up from vb6. When run from the VS.NET IDE, the program shows no errors and runs fine. When the output exe...
5
by: Lucvdv | last post by:
Can someone explain why this code pops up a messagebox saying the ThreadAbortException wasn't handled? The first exception is reported only in the debug pane, as expected. The second (caused by...
5
by: Samuel R. Neff | last post by:
When you have an unhandled exception in vb.net how do you view the exception information in the debugger? In C# the debugger creates a local variable that points to the exception and you can...
0
by: Colmeister | last post by:
I recently read Jason Clark's excellent article on Unhandled Exceptions (http://msdn.microsoft.com/msdnmag/issues/04/06/NET/default.aspx) and have attempted to incorporate the features he talks...
5
by: Simon Tamman {Uchiha Jax} | last post by:
Now this is bugging me. I just released software for a client and they have reported an unhandled stack overflow exception. My first concern is that the entirity of the UI and any threaded...
0
by: Bob | last post by:
If I induce and unhandled exception in my vb.net code for instance using '-- just a simple "object not initialized" exception (should read "as new") Dim x As Specialized.NameValueCollection ...
1
by: Bob | last post by:
In Vs 2005 you have new applicationsEvents.vb I was testing it in a simple app and found that it was easier to implement unhandled exception management tah it was in Vs2003 (vb.net) You can, if you...
4
by: bg_ie | last post by:
Hi, I have the following Program.cs - namespace TestFrameworkApplication { static class Program { /// <summary> /// The main entry point for the application.
5
by: =?Utf-8?B?c3VydHVyeg==?= | last post by:
Hi, I feel like a noob for asking this. When I publish a VB windows application, I want to disable the ability of the the user to continue when there is an unhandled exception. For example,...
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.