PC Review


Reply
Thread Tools Rate Thread

Closing modal dialog causes main window to flash/flicker

 
 
=?Utf-8?B?YWdlZWphczE=?=
Guest
Posts: n/a
 
      19th May 2004
Hello and thanks for any help
I've noticed that my main application window has a bad Flash/Flicker sometimes when I close a modal dialog box. Sometimes it also loses focus, and gets placed behind another window that was not originally on top. I perform the dispose inside of the dialog, for instance when a user clicks on the Ok button as follows

private void okButton_Click(object o, EventArgs e

/*Perfrom some action*
this.Dispose()


Does anyone know why this is happening? Thanks.
 
Reply With Quote
 
 
 
 
Claire
Guest
Posts: n/a
 
      19th May 2004
Have you tried calling Close() rather than dispose?


 
Reply With Quote
 
 
 
 
=?Utf-8?B?Q2xvc2Ugd29ya2VkLg==?=
Guest
Posts: n/a
 
      19th May 2004
Thanks for the response Claire,

That seemed to do the trick and things close a lot cleaner. I guess the Close() methods forces a paint before other calculations are done or something. Well, either way, thanks alot.

Jason Agee
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
RE: Refresh main web page After closing modal Dialog =?Utf-8?B?QW5uYQ==?= Microsoft Dot NET Framework 1 26th Apr 2006 03:47 PM
Closing event in a MID Child form I don't know if the child form is closing or the main form is closing **Developer** Microsoft C# .NET 1 19th Oct 2005 04:51 PM
Modeless Dialog calls Modal Dialog. Hide causes application to lose focus. Tom Clement Microsoft Dot NET Framework Forms 3 27th Jun 2005 09:44 AM
Modal Dialog box - but only modal for the owner Haim Microsoft Dot NET Framework Forms 0 11th Aug 2004 01:33 PM
Closing Modal child dialog causes parent window to close JerryK Microsoft Dot NET Framework Forms 2 17th Sep 2003 01:53 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:26 AM.