Beispiel #1
0
    protected void btnregistersubmit_Click(object sender, ImageClickEventArgs e)
    {
        Security.UserInfo usr = new Security.UserInfo();

        usr.Lname = txtfirst.Text;
        usr.Fname = txtlast.Text;
        usr.Username = txtemails.Text;
        usr.Password = txtpasswords.Text;

        string szID = usr.CheckLogin(usr);
        if (szID == "0")
        {
            usr.RegisterUser(usr);
            Response.Redirect("~/Default2.aspx");
        }
        else
        {
            //  lblemail.Text = "Email found";
        }
    }
Beispiel #2
0
    protected void insert(object sender, EventArgs e)
    {
        Security.UserInfo usr = new Security.UserInfo();

        usr.Lname= txtfirst.Text;
        usr.Fname = txtlast.Text;
        usr.Username = txtemail.Text;
        usr.Password = txtpassword.Text;

        string szID = usr.CheckLogin(usr);
        if (szID == "0")
        {
            usr.RegisterUser(usr);
            Response.Redirect("login.aspx");
        }
        else
        {
            lblemail.Text = "Email found";
        }
    }