|
-
Jun 19th, 2007, 09:34 PM
#1
Thread Starter
Fanatic Member
[RESOLVED] Help with MDI
Guys help please..I have a MDI form and in the parent form I have 2 buttons, Button1 and Button2, when I click the Button1 Child Form1 will be shown and button1 will be disabled and the same with Button2, when I click Button 2 Child Form2 will be shown and Button2 will be disbaled but how will I enable Button1 and close Form1 when the user click on Button2 or vice versa so as only One(1) child form is open/shown.Any help please. Thanks!
Last edited by daimous; Jun 19th, 2007 at 09:50 PM.
-
Jun 19th, 2007, 10:28 PM
#2
Hyperactive Member
Re: Help with MDI
You can make a public properties in your MDI Form for your buttons (1 & 2) in order to manipulate the disable/enable property of it, so when you load your form1 it should be like this or something:
Code:
Frmparent parnt;
private void Form1_Load(object sender, EventArgs e)
{
parnt = (Frmparent)MdiParent;
parnt.Btn1.Enabled = false;
}
so when you closed your form1 in the closed event you can easily set "parnt.Btn1.Enabled = true;
hope that helps.
-
Jun 20th, 2007, 06:28 PM
#3
Thread Starter
Fanatic Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|