protected void btnRegister_Click(object sender, EventArgs e) { bool flag = LoginDAL.isAvailable(txtUserId1.Text); if (flag == true) { string message = ""; User user = LoginDAL.Register(txtFirstname.Text, txtLastname.Text, txtUserId1.Text, txtPassword1.Text, txtEmail.Text, txtMobile.Text, txtCity.Text, out message); if (user == null) { lblStatus.Text = message; } else { lblWelcome.Text = "Hello " + user.userid + " !"; Session["USER"] = user.userid; Session["LOGGED"] = "1"; //Response.Redirect("Selling.aspx"); } } }