protected void btnregister_Click(object sender, EventArgs e) { con.Open(); { cmd.CommandText = "usp_adduser"; cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.AddWithValue("@user_name", txtusername.Text); cmd.Parameters.AddWithValue("@password", txtpassword.Text); cmd.Parameters.AddWithValue("@firstname", txtfname.Text); cmd.Parameters.AddWithValue("@lastname", txtlname.Text); cmd.Connection = con; cmd.ExecuteNonQuery(); int check = 0; check = cmd.ExecuteNonQuery(); if (check == 1) { con.Close(); } else { Response.Write("Error"); } } con.Close(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)