Re: Help with error message on Application close
From: Phil jenson (phil.jenson_at_jenson.co.uk.nospam)
Date: 10/01/04
- Next message: Chris Jobson: "Re: How to derive from TreeNode?"
- Previous message: Just D.: "Re: SP 1.1 .NET"
- In reply to: Jim H: "Re: Help with error message on Application close"
- Next in thread: Jim H: "Re: Help with error message on Application close"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 1 Oct 2004 16:13:15 +0100
Jim,
As mentioned before I suspect your problem is related to calling Dispose
from a thread other than the main UI thread. Is it possible to place a break
point on a catch statement within you Dispose method and check the call
stack and also the thread that it is called on? If the application quits
without allowing you to debug then try writing relevant information to a
trace file.
I appreciate you say you never call Dispose, so I assume you have shown the
form with myForm.Show() as this is the main (only?) way Dispose would be
called automatically, when the form is closed. It should be called on the
main message handling thread, in which case the stack trace/thread display
should confirm this.
Alternatively are you doing something on another thread at the point of
closing the form? Are you doing and GDI+ drawing for example or anything
which (indirectly) uses windows handles? Again look at the other threads
active to see (if possible) what they are doing when the exception occurs.
Or do you already no for a fact it is not thread related?
If its easily reproducible and your code is easy to transfer than I would be
willing to have a look if you want to send it. I offer not as an expert on
these issues but because sometimes it helps to have a fresh view on a
problem.
Hope this gives you some ideas.
Phil...
"Jim H" <nospam@jimsaccount.com> wrote in message
news:eBLpZK2pEHA.3524@TK2MSFTNGP15.phx.gbl...
> Yes, I am still having that problem but it's very very intermittent. I'm
> still trying to find a pattern so I can duplicate the problem more
> regularly.
>
> Jim
- Next message: Chris Jobson: "Re: How to derive from TreeNode?"
- Previous message: Just D.: "Re: SP 1.1 .NET"
- In reply to: Jim H: "Re: Help with error message on Application close"
- Next in thread: Jim H: "Re: Help with error message on Application close"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|