PC Review Forums Newsgroups Microsoft DotNet Microsoft Dot NET Framework Forms How-to exit button click event of ( C#) modal dialog without exiting dialog?

Reply

How-to exit button click event of ( C#) modal dialog without exiting dialog?

 
Thread Tools Rate Thread
Old 02-06-2005, 02:30 AM   #1
Lew Barnesson
Guest
 
Posts: n/a
Default How-to exit button click event of ( C#) modal dialog without exiting dialog?


Hi all,

In the OK_Click event of my custom modal dialog I determine that another
action must be accomplished before exiting (thus closing) the dialog. But
how to do this? Whatever I have tried up to now has caused the dialog to be
exited and closed.

I'm sure there must be a way. Can someone suggest a solution? Thanks.

- Lew




  Reply With Quote
Old 02-06-2005, 02:39 PM   #2
Chris Dunaway
Guest
 
Posts: n/a
Default Re: How-to exit button click event of ( C#) modal dialog without exiting dialog?

What is the DialogResult of the OK button? You might want to check it
and clear it if it is set to something.

Just a thought

  Reply With Quote
Old 02-06-2005, 04:24 PM   #3
Lew Barnesson
Guest
 
Posts: n/a
Default Re: How-to exit button click event of ( C#) modal dialog without exiting dialog?

Chris,

Thanks for your reply. The DialogResult is set to the OK button. But this
check is made in the calling form, and I need to intercept and get out of
the dialog's OK button click event *without* exiting/closing the dialog. I
don't know how to do that. :-(

- Lew
"Chris Dunaway" <dunawayc@gmail.com> wrote in message
news:1117719552.600515.288200@g44g2000cwa.googlegroups.com...
> What is the DialogResult of the OK button? You might want to check it
> and clear it if it is set to something.
>
> Just a thought
>



  Reply With Quote
Old 02-06-2005, 11:03 PM   #4
Lew Barnesson
Guest
 
Posts: n/a
Default Re: How-to exit button click event of ( C#) modal dialog without exiting dialog?

Hello All,

I found the answer to my problems here
http://www.vbinfozine.com/t_wfdlg.shtml and it works perfectly!

I offer this to others that, I am sure, have the same problems.

- Lew
"Lew Barnesson" <lewb007@centurytel.net> wrote in message
news:N72dnTBXz-in_APfRVn-1g@centurytel.net...
> Hi all,
>
> In the OK_Click event of my custom modal dialog I determine that another
> action must be accomplished before exiting (thus closing) the dialog. But
> how to do this? Whatever I have tried up to now has caused the dialog to
> be exited and closed.
>
> I'm sure there must be a way. Can someone suggest a solution? Thanks.
>
> - Lew
>
>
>
>



  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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off