views:

78

answers:

2

I'm trying to create a child form that helps the user to enter data for a field in the parent form. I want this child form to be modal, but I don't know what I need to do to make this form modal.

Perhaps there's a different type of item I need to use; if so, let me know.

+11  A: 

Use Form.ShowDialog()

As Bob mentioned, you should set Form.DialogResult accordingly on your modal form.

Jon B
Don't forget about setting DialogResult on the Buttons of said Form
Bob
+3  A: 

Use the ShowDialog() function instead of Show() when you display the child form.

Paul Keister