コード例 #1
0
 private void btnLocation_Click(object sender, EventArgs e)
 {
     if (Utility.gblnAccessControl)
     {
         if (!Utility.gblnChildPrivileges(strComID, Utility.gstrUserName, 58))
         {
             MessageBox.Show("You have no Permission to Access", "Privileges", MessageBoxButtons.OK, MessageBoxIcon.Warning);
             return;
         }
     }
     if (System.Windows.Forms.Application.OpenForms["frmLocation"] as frmLocation == null)
     {
         frmLocation objfrm = new frmLocation();
         objfrm.m_action    = (int)Utility.ACTION_MODE_ENUM.ADD_MODE;
         objfrm.lngFormPriv = 58;
         objfrm.strFormName = "Location";
         objfrm.Show();
         objfrm.MdiParent = this.MdiParent;
     }
     else
     {
         frmLocation objfrm = (frmLocation)Application.OpenForms["frmLocation"];
         objfrm.strFormName = "Location";
         objfrm.lngFormPriv = 58;
         objfrm.Focus();
         objfrm.MdiParent = this.MdiParent;
     }
 }
コード例 #2
0
        private void btnLocation_Click(object sender, EventArgs e)
        {
            foreach (Form frmCheck in MdiChildren)
            {
                if (frmCheck.GetType() == typeof(frmLocation))
                {
                    frmCheck.Activate();
                    return;
                }
            }
            Form frmChild = new frmLocation
            {
                MdiParent = this
            };

            frmChild.Show();
        }
コード例 #3
0
        private void Picture_Click(object sender, EventArgs e)
        {
            frmLocation fLocation = new frmLocation(location.ID);

            fLocation.ShowDialog();
        }
コード例 #4
0
ファイル: MainForm.cs プロジェクト: harishkumarhn/Marble
        private void locationToolStripMenuItem_Click(object sender, EventArgs e)
        {
            frmLocation frm = new frmLocation();

            frm.ShowDialog();
        }