I am using the following Regular Expression Validator to ensure the password enter meets the requirements of 1 upper case, 1 lower case, 1 number, and 1 allowed special character:
<asp:RegularExpressionValidator ID="rev_txtNewPassword" runat="server" Display="Dynamic"
ErrorMessage=" Password does not meet requirements" ControlToValidate="txtNewPassword" ValidationGroup="password"
ValidationExpression="^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[!@#$%^&*]).{8,16}$"></asp:RegularExpressionValidator>
This works in FireFox, Chrome, Safari, Internet Explorer 8 and 9. It just doesn’t work on Internet Explorer 7. No matter what is entered into the password box, it says it doesn’t meet the requirements. This is part of a custom SharePoint 2010 web part.
Any ideas why the expression validator isn’t working only on IE7?
Thanks
As the OP requests, I put the solution here so everybody can view this question as solved. The problem is caused by the IE regex lookahead bug and the original solution is made by Alan Moore. The solution can be found here:
Solution