Authentication Authorization ASP.Net Tutorial

<%@ Page Language="C#" %>

    protected void Button1_Click(object sender, EventArgs e)
    {
        try
        {
            Membership.CreateUser(TextBox1.Text.ToString(), TextBox2.Text.ToString());
            Label1.Text = "Successfully created user " + TextBox1.Text;
        }
        catch (MembershipCreateUserException ex)
        {
            Label1.Text = "Error: " + ex.ToString();
        }
    }



    Creating a User


    
        

Create User


        Username
            
        
        Password
                         TextMode="Password">
        
                         OnClick="Button1_Click" />