Example #1
0
        private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
        {
            frmaddfood f = new frmaddfood();

            this.Hide();
            f.Show();
        }
Example #2
0
        private void cmdLogin_Click(object sender, EventArgs e)
        {
            localhost.Service1 s = new localhost.Service1();
            bool Adminisvalid, Adminisvalidpassed;

            s.Adminisvalid(txtusername.Text, txtpassword.Text, out Adminisvalid, out Adminisvalidpassed);

            if (Adminisvalid)
            {
                MessageBox.Show("Valid admin");
                frmaddfood l = new frmaddfood();
                this.Hide();
                l.Show();
            }
            else
            {
                MessageBox.Show("inValid admin");
            }
        }