I need to create a regular expression to check if the password contains - atleast 1 Capital letter - atleast 1 Special character - atleast 1 numeric
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35237
7
posted
0
Welcome to JavaRanch.
On your way in you may have missed that we have a policy on screen names here at JavaRanch. Basically, it must consist of a first name, a space, and a last name, and not be obviously fictitious. Since yours does not conform with it, please take a moment to change it, which you can do right here.
Thank, i tried it, it works in a stand alone java program, not in struts though, inspite of removing the "\" symbol
prakash chandra
Greenhorn
Joined: Aug 14, 2007
Posts: 24
posted
0
Hi, Following is the simple code which will fulfill your requirements. It depends on what special character you want in the Password. You can just append the special character you want in static variable SPECIAL of following code.
[ August 22, 2007: Message edited by: prakash chandra ]