Application vanishes

U

Urs Vogel

Hi

we encountered a strange problem in our Windows client. It sometimes
(fortunately rarely) just disappears with all open windows, without throwing
an exception, either after a click on any control or a keystroke, although
the app makes 100% use of structured exception handling, including all event
handlers and Main(). For threaded ops, we make strict use of InvokeRequired.
No WinAPI calls are made, no unmanaged code is used in this client.

What could cause a 100% .Net based app to vanish without warning?

The major components and namespaces we use:

Windows.Forms
Threading
Remoting
Infragistics TreeView
DevComponents DotNetBar

Thanks for any hints. Urs
 
C

Champika Nirosh

My guess ais some .Dispose mathod wrongly put in an event delegate.. or an
override event..

Nirosh.
 
R

Richard Blewett [DevelopMentor]

Hi Urs,

The only time I've seen this behavior is with a background thread calling the UI directly. I know you have said you use the InvokeRequired/BeginInvoke pattern everywhere, but it may be worth double checking just in case.

Regards

Richard Blewett - DevelopMentor
http://staff.develop.com/richardb/weblog

nntp://news.microsoft.com/microsoft.public.dotnet.languages.csharp/<[email protected]>

Hi

we encountered a strange problem in our Windows client. It sometimes
(fortunately rarely) just disappears with all open windows, without throwing
an exception, either after a click on any control or a keystroke, although
the app makes 100% use of structured exception handling, including all event
handlers and Main(). For threaded ops, we make strict use of InvokeRequired.
No WinAPI calls are made, no unmanaged code is used in this client.

What could cause a 100% .Net based app to vanish without warning?
 
U

Urs Vogel

Richard

We double checked the InvokeRequired, which is mainly used when the server
sends event messages for that client. The problem is that it may happen on
any control, absolutely arbitrary. For instance, it happened to myself when
clicking on the boolean drop down in a property grid, where absolutely no
code is executed except the standard internal propGrid bool dropdown
handler. At this time, no timers, background threads or call backs were
running/expected, no events received from the server, the app was in idle
state. And it only happens on a click or keystroke, never by itself. Does
this give you some more ideas what else we could look for?

Thanks, Urs
 
R

Richard Blewett [DevelopMentor]

Does it happen on all machines the application is installed on or only one in particular? (just wondering if one of the runtime files on that machine ahs got corrupted)

Regards

Richard Blewett - DevelopMentor
http://staff.develop.com/richardb/weblog

Richard

We double checked the InvokeRequired, which is mainly used when the server
sends event messages for that client. The problem is that it may happen on
any control, absolutely arbitrary. For instance, it happened to myself when
clicking on the boolean drop down in a property grid, where absolutely no
code is executed except the standard internal propGrid bool dropdown
handler. At this time, no timers, background threads or call backs were
running/expected, no events received from the server, the app was in idle
state. And it only happens on a click or keystroke, never by itself. Does
this give you some more ideas what else we could look for?

Thanks, Urs
 
S

Stefan Simek

What version of the framework do you use?

I've encountered this problem with the 1.0, and I've also posted about it,
but I never got any real response. Since 1.1, I haven't seen the
applications disappear, even the ones that kept disappearing frequently were
cured after recompiling under 1.1. But I remember reading an article some
time ago about internal CLR exceptions that aren't catched by exception
handlers and they just shut down the application. Maybe it's just easier in
the 1.0 to trigger such exception.

HTH,
Stefan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top