Exemplo n.º 1
0
        private void first()
        {
            string sqlstring;

            sqlstring = "select 值 from z_system where 属性=2";
            DataTable dt = return_select(sqlstring);

            if (dt.Rows[0]["值"].ToString() == "0")
            {
                Form first_v = new systemall.first_view();
                first_v.MdiParent = this;
                //passs.WindowState = FormWindowState.Maximized;
                first_v.StartPosition = FormStartPosition.CenterScreen;//窗体居中
                first_v.Show();
            }
        }
Exemplo n.º 2
0
 private void 提示设置ToolStripMenuItem_Click(object sender, EventArgs e)
 {
     try
     {
         int index = a_sqlconn.other.HaveOpened(this, "first_view");
         if (index == -1)
         {
             Form first = new systemall.first_view();
             first.MdiParent = this;
             //passs.WindowState = FormWindowState.Maximized;
             first.StartPosition = FormStartPosition.CenterScreen;//窗体居中
             first.Show();
         }
         else
         {
             this.MdiChildren[index].Show();
         }
     }
     catch (Exception ex)
     {
         ex.errormess();
     }
 }