I want to give a regex pattern to validate Aadhar card number and Pan card number in UiPath apps textbox.
Validation:
Aadhar card : Only 12 digits can be used. For eg: 123456789012
Pan card: 5 Upper case letters, 4 digits and 1 upper case letter For eg: ABCDE1234F
Please provide me the pattern which can validate and throw error if it is in incorrect format.
For Aadhar card - \d{12}
for pan card - [A-Z]{5}[0-9]{4}[A-Z]{1}
try these patterns
Happy Automation!!
Tried this but it is not validating
Did you validated your input, how you are getting.
can you please send your input with dummy data and you can try by using regex101
Regular expression tester with syntax highlighting, explanation, cheat sheet for PHP/PCRE, Python, GO, JavaScript, Java, C#/.NET, Rust.
It is validating on regex 101 website, but when I am entering the regex pattern in UiPath apps regex field then it is not throwing an error if I enter any text or number in that textbox.
@sarvesh.b ,
Pass the regex like this
/{[A-Z]{5}[0-9]{4}[A-Z]{1}}/
The UiPath Documentation Portal - the home of all our valuable information. Find here everything you need to guide you in your automation journey in the UiPath ecosystem, from complex installation guides to quick tutorials, to practical business...
1 Like
@sarvesh.b
Can you go throw below thread once
I need to use regex for the username and password for my app. How do declare my regex for a password which must have 8 characters, 1 special character, 1 number, and 1 small and caps letter? In addition, I need to check email with regex ( Gmail, Microsoft or anything)
[image]
system
(system)
Closed
April 11, 2025, 6:29am
8
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.