Hi,
Ho do I open a winform within another winform and disable the parent?
I want to create a log in. So I create a form and this form open the log in form, but I want to disable the one that opens the log in form.
thanks
Hi,
Ho do I open a winform within another winform and disable the parent?
I want to create a log in. So I create a form and this form open the log in form, but I want to disable the one that opens the log in form.
thanks
From the parent form, use the ShowDialog method of the child form, optionally passing a reference to the parent form:
ChildForm x = new ChildForm();
x.ShowDialog(this);
Why don't you open your logon form modally, like this:
form.ShowDialog();
This way the user can't do anything with the parent form that launched the logon screen.