Re: Closing down a hierarchy of modal windows nicely
- From: "Dave Sexton" <dave@jwa[remove.this]online.com>
- Date: Wed, 22 Nov 2006 00:26:47 -0500
Hi Michael,
The recursion is much nicer. I assume that the OP will probably find this
code to be more suitable.
--
Dave Sexton
"Michael C" <nospam@xxxxxxxxxx> wrote in message
news:Oa22QbeDHHA.4060@xxxxxxxxxxxxxxxxxxxxxxx
"Dave Sexton" <dave@jwa[remove.this]online.com> wrote in message
news:uXASoIeDHHA.1748@xxxxxxxxxxxxxxxxxxxxxxx
And I don't think your code is simpler at all, BTW. I've glanced at it
twice and I have no idea what it's doing - I'm just assuming that it
works :)
Here's a simplified version of mine. This required 4 lines of code in one
location in the app and does not require code in each form.
private void CloseChildForms(Form ParentForm)
{
foreach(Form form in ParentForm.OwnedForms)
{
CloseChildForms(form);
form.Close();
}
}
Michael
.
- References:
- Closing down a hierarchy of modal windows nicely
- From: Chukkalove
- Re: Closing down a hierarchy of modal windows nicely
- From: Dave Sexton
- Re: Closing down a hierarchy of modal windows nicely
- From: Marc Vangrieken
- Re: Closing down a hierarchy of modal windows nicely
- From: Dave Sexton
- Re: Closing down a hierarchy of modal windows nicely
- From: Michael C
- Re: Closing down a hierarchy of modal windows nicely
- From: Dave Sexton
- Re: Closing down a hierarchy of modal windows nicely
- From: Michael C
- Re: Closing down a hierarchy of modal windows nicely
- From: Dave Sexton
- Re: Closing down a hierarchy of modal windows nicely
- From: Michael C
- Re: Closing down a hierarchy of modal windows nicely
- From: Dave Sexton
- Re: Closing down a hierarchy of modal windows nicely
- From: Michael C
- Closing down a hierarchy of modal windows nicely
- Prev by Date: Re: Thread ending
- Next by Date: GUI Buttons like VISTA
- Previous by thread: Re: Closing down a hierarchy of modal windows nicely
- Next by thread: Re: Closing down a hierarchy of modal windows nicely
- Index(es):