Validate strong passwords using RegularExpressionValidator in Asp .Net

 In this article we will see how to enforce users to create strong passwords. To validate for strong passwords we will use RegularExpressionValidator with REGEX. For this example we will take three different scenarios:  

  1. Validate strong password which must have 8-10 characters long with at least one numeric character.
  2. Validate strong password which must have 8-10 characters long with at least one numeric character, one alphabet character and one special character.
  3. Validate strong password which must have 8-10 characters long with at least one numeric character, one upper case character and one special character.
You may also like my previous validation related posts:
  1. Remove Blank spaces accuired by validation messages.
  2. Show Images in error messages.
  3. Apply Custom CSS to ValidationSummary Control. 
 
Case 1: Validation for 8-10 characters with alphabets,numbers and no special characters.
 
   
                    
 
Output:
 
Validate-Strong-Passwords-In-Asp-Net-CodingFusion
 
Case2: Validation for 8-10 characters with characters,numbers and special characters.
 

                    
 
Output:
 
Validate-Strong-Passwords-In-Asp-Net-Codingfusion
Strong-Password-Validation-Example-In-Asp-Net
 
Case3: Validation for 8-10 characters with characters,numbers,1 upper case letter and special characters.
 

                    
 
Output:
 

 

 
Best quality Asp .Net Ajax Control Toolkit tutorials.

Give your valuable comments.

Name
Email
Comment
7 + 4 =
 

About Us | Terms of Use | Privacy Policy | Disclaimer | Contact Us Copyright © 2012-2024 CodingFusion
50+ C# Programs for beginners to practice