Click here to Skip to main content
14,662,597 members
Home » Discussions » C#
   

C#

 
GeneralRe: Closing and recreating a form Pin
SimpleData14-Jun-09 3:36
MemberSimpleData14-Jun-09 3:36 
GeneralRe: Closing and recreating a form Pin
Henry Minute14-Jun-09 3:40
MemberHenry Minute14-Jun-09 3:40 
AnswerRe: Closing and recreating a form Pin
Luc Pattyn14-Jun-09 4:14
sitebuilderLuc Pattyn14-Jun-09 4:14 
GeneralRe: Closing and recreating a form Pin
SimpleData14-Jun-09 4:43
MemberSimpleData14-Jun-09 4:43 
GeneralRe: Closing and recreating a form Pin
Luc Pattyn14-Jun-09 4:49
sitebuilderLuc Pattyn14-Jun-09 4:49 
GeneralRe: Closing and recreating a form Pin
SimpleData14-Jun-09 4:52
MemberSimpleData14-Jun-09 4:52 
GeneralRe: Closing and recreating a form Pin
Dave Kreskowiak14-Jun-09 4:58
mveDave Kreskowiak14-Jun-09 4:58 
GeneralRe: Closing and recreating a form Pin
Dave Kreskowiak14-Jun-09 4:55
mveDave Kreskowiak14-Jun-09 4:55 
Just because the property is there doesn't mean it should be used.

I concur with Luc, your approach is completely wrong and unsupportable. I really can't suggest a replacement because it isn't clear what you're trying to accomplish.

Also, when you show a form with ShowDialog, you are responsible for calling Dispose on it to free up unmanaged resources before the object goes out of focus and is destroyed. As it stands now, your code leaks system resources, specifically, window handles. Your code, if left running long enough, will eventually crash Windows.


A guide to posting questions on CodeProject[^]



Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic
     2006, 2007, 2008




GeneralRe: Closing and recreating a form Pin
SimpleData14-Jun-09 5:07
MemberSimpleData14-Jun-09 5:07 
GeneralRe: Closing and recreating a form Pin
Dave Kreskowiak14-Jun-09 5:08
mveDave Kreskowiak14-Jun-09 5:08 
GeneralRe: Closing and recreating a form Pin
SimpleData14-Jun-09 5:13
MemberSimpleData14-Jun-09 5:13 
GeneralRe: Closing and recreating a form Pin
DidiKunz14-Jun-09 7:29
MemberDidiKunz14-Jun-09 7:29 
GeneralRe: Closing and recreating a form Pin
SimpleData14-Jun-09 8:19
MemberSimpleData14-Jun-09 8:19 
GeneralRe: Closing and recreating a form Pin
Dave Kreskowiak15-Jun-09 0:39
mveDave Kreskowiak15-Jun-09 0:39 
GeneralRe: Closing and recreating a form Pin
SimpleData15-Jun-09 1:09
MemberSimpleData15-Jun-09 1:09 
GeneralRe: Closing and recreating a form Pin
Henry Minute14-Jun-09 9:57
MemberHenry Minute14-Jun-09 9:57 
GeneralRe: Closing and recreating a form Pin
Luc Pattyn14-Jun-09 10:08
sitebuilderLuc Pattyn14-Jun-09 10:08 
GeneralRe: Closing and recreating a form Pin
Henry Minute14-Jun-09 10:17
MemberHenry Minute14-Jun-09 10:17 
GeneralRe: Closing and recreating a form Pin
Luc Pattyn14-Jun-09 10:23
sitebuilderLuc Pattyn14-Jun-09 10:23 
GeneralRe: Closing and recreating a form Pin
SimpleData15-Jun-09 1:09
MemberSimpleData15-Jun-09 1:09 
AnswerRe: Closing and recreating a form Pin
Jacek Gajek15-Jun-09 23:21
MemberJacek Gajek15-Jun-09 23:21 
GeneralRe: Closing and recreating a form Pin
SimpleData15-Jun-09 23:40
MemberSimpleData15-Jun-09 23:40 
QuestionHandwritten character recognition in c# Pin
indikakulasekara13-Jun-09 22:20
Memberindikakulasekara13-Jun-09 22:20 
AnswerRe: Handwritten character recognition in c# Pin
Henry Minute13-Jun-09 23:57
MemberHenry Minute13-Jun-09 23:57 
QuestionHow to cancel the adobe reader opening when You click a link on IE? Pin
svt gdwl13-Jun-09 19:47
Membersvt gdwl13-Jun-09 19:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.