コード例 #1
0
        //新建
        private void tsm_NewItem_Click(object sender, EventArgs e)
        {
            //实例化一个子窗体对象
            FrmChild child = new FrmChild();

            //设置窗体的父窗体
            child.MdiParent = this;
            child.Show();
        }
コード例 #2
0
        //关闭
        private void tsm_Close_Click(object sender, EventArgs e)
        {
            FrmChild frm = (this.ActiveMdiChild) as FrmChild;

            frm.Close();
        }