Validation ASP.Net Tutorial

<%@ Page Language="VB" %>

    Protected Sub Button1_Click(sender As Object, e As EventArgs)
       Label1.Text = "Passwords match"
    End Sub



    CompareFieldValidator


    
        
            Password

                         TextMode="Password">
              
                         Runat="server" ErrorMessage="Passwords do not match!" 
             ControlToValidate="TextBox2" 
             ControlToCompare="TextBox1">
        
            Confirm Password

                         TextMode="Password">
        
                         Runat="server" Text="Login">