⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 seekersreg.aspx.cs

📁 electronic CURRICULUM VITAE
💻 CS
字号:
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;
using System.IO;

public partial class SeekersReg : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    protected void TextBox1_TextChanged(object sender, EventArgs e)
    {

    }

    protected void TextBox3_TextChanged1(object sender, EventArgs e)
    {

    }
    

    protected void TextBox5_TextChanged(object sender, EventArgs e)
    {

    }
    protected void TextBox2_TextChanged(object sender, EventArgs e)
    {

    }


    protected void Button1_Click(object sender, EventArgs e)
    {

        using (SqlCommand command = new SqlCommand())
        {
            command.Connection = new SqlConnection(ConfigurationManager.ConnectionStrings["ConnectionStringUser"].ConnectionString);
            command.CommandText = @"insert into [Seeker](username,password,conPassword,emirate,email)
						values( @username, @password,@conPassword , @emirate , @email)";
            command.Parameters.Add("@username", SqlDbType.VarChar, 50).Value = TextBox1.Text;
            command.Parameters.Add("@password", SqlDbType.VarChar, 40).Value = TextBox2.Text;
            command.Parameters.Add("@conPassword", SqlDbType.VarChar, 40).Value = TextBox3.Text;
            command.Parameters.Add("@emirate", SqlDbType.VarChar, 20).Value =EmiDropDownList1.SelectedItem.Text;
            command.Parameters.Add("@email", SqlDbType.VarChar, 60).Value = TextBox5.Text;

            command.Connection.Open();
            command.ExecuteNonQuery();


            Response.Redirect("Login.aspx");

        }

    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -