private void button1_Click(object sender, EventArgs e) { User_food_list f = new User_food_list(); this.Hide(); f.Show(); }
private void linkLabel2_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { localhost.Service1 server = new localhost.Service1(); bool isvaliduser; bool isvaliduserpassed; server.isValidUser(txtUsername.Text, txtpassword.Text, out isvaliduser, out isvaliduserpassed); if (isvaliduser) { MessageBox.Show("valid user"); User_food_list f = new User_food_list(); this.Hide(); f.Show(); } else { MessageBox.Show("invalid user"); } txtUsername.Text = " "; txtpassword.Text = " "; }