}
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{ //
This.LayoutMdi(MdiLayout.TileVertical);
}
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{ // () ,
if (this.ActiveMdiChild!= null) ActiveMdiChild.Close();
}
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{ //
/* for (int i = MdiChildren.Length - 1; i >= 0; i--)
MdiChildren[i].Close();*/
while (this.ActiveMdiChild!= null) ActiveMdiChild.Close();
}
ActiveMdiChild , .
MdiChildren .
. . . FormA public. Form4. : public Form1 f1;
:
private void FormA_Click(object sender, EventArgs e)
{
Form4 f4;
f4 = new Form4();
f4.MdiParent = this;
FormA.Enabled = false; //
f4.f1 = this; // Form4
F4.Show();
}
( FormA) . : : , ´, .. . , :
FormClosed ( ) FormClosing ( ). . , :
private void Form4_FormClosed(object sender, FormClosedEventArgs e)
{
f1.FormA.Enabled = true;
}
MDI- . . .
1. ?
2. ? ?
3. MDI- SDI-.
- Microsoft Visual Studio 2005
, C# ( - ), Microsoft Visual Studio 2005. , : . , :
|
|
1. . , .
2. , ( ) . () ( ) Visual Studio.
3. ( ); () .
4. /.