示例#1
0
        private void materialFlatButton1_Click(object sender, EventArgs e)
        {
            if (String.IsNullOrEmpty(materialSingleLineTextField1.Text))
            {
                MetroFramework.MetroMessageBox.Show(this, " please  enter your username ! ", "message", MessageBoxButtons.RetryCancel, MessageBoxIcon.Error);
                materialSingleLineTextField1.Focus();
            }
            else if (String.IsNullOrEmpty(materialSingleLineTextField2.Text))
            {
                MetroFramework.MetroMessageBox.Show(this, " please  enter  your password !", "message", MessageBoxButtons.RetryCancel, MessageBoxIcon.Error);
                materialSingleLineTextField2.Focus();
            }
            ///
            if (materialSingleLineTextField1.Text != "" && materialSingleLineTextField2.Text != "")
            {
                if (materialSingleLineTextField1.Text.Equals("school") && materialSingleLineTextField2.Text.Equals("12345"))
                {
                    this.Hide();

                    mainf f = new mainf();
                    f.ShowDialog();
                }
                else
                {
                    MetroFramework.MetroMessageBox.Show(this, " your user name or password is incorrect  !", "message", MessageBoxButtons.RetryCancel, MessageBoxIcon.Error);
                }
            }//iflkbir
        }
示例#2
0
        private void mainf_Load(object sender, EventArgs e)
        {
            blink.Visible = false;

            _instance = this;
            dashbord d = new dashbord();

            d.Dock = DockStyle.Fill;
            mpanel.Controls.Add(d);
        }