示例#1
0
 private void Form_Main_Load(object sender, EventArgs e)
 {
     labelRegister.Text = SoftRegister.GetFreeRegisterNum();
     if (SoftRegister.IsRegister() == true)
     {
         panelRegister.Visible    = false;
         menuStrip.Enabled        = true;
         toolStrip.Enabled        = true;
         formMainShow.MdiParent   = this;
         formMainShow.WindowState = FormWindowState.Maximized;
         formMainShow.Show();
     }
 }
示例#2
0
        private void Form_Main_Load(object sender, EventArgs e)
        {
            string      strHostIP = "";
            IPHostEntry oIPHost   = Dns.GetHostEntry(Environment.MachineName);

            if (oIPHost.AddressList.Length > 0)
            {
                foreach (IPAddress ip in oIPHost.AddressList)
                {
                    strHostIP += " " + ip.ToString();
                }
            }
            //this.Text = strHostIP;

            labelRegister.Text = SoftRegister.GetFreeRegisterNum();
            if (SoftRegister.IsRegister() == true)
            {
                panelRegister.Visible  = false;
                menuStrip.Enabled      = true;
                toolStrip.Enabled      = true;
                formMainShow.MdiParent = this;
                formMainShow.Show();
            }
        }