A
alastair.slater
Hi all,
Can anyone help please? I'm using the following code to validate a
password entered by new users in an <asp:Textbox ... />:
<asp:RegularExpressionValidator
ID="RegularPassword"
runat="server"
ControlToValidate="RegisterPassword"
SetFocusOnError="True"
ValidationExpression=".*(?=.{8,})(?=(.*\d){2,})(?=(.*\W){1,}).*"
ErrorMessage="Invalid password (min: 8 chars, including 2 numbers
and 1 non-alpha)."
ToolTip="Invalid password."
CssClass="RegistrationError"
Font-Size="11px">
</asp:RegularExpressionValidator>
(...for info, there is also a RequiredFieldValidator associated with
the same control).
The code works correctly in FireFox 1.5 and 2.0, and also in IE7. When
I try the code in IE6, the validation works for invalid entries (i.e.
it outputs the ErrorMessage text), but if a valid password is entered,
IE6 crashes with the error 'The instruction at "0x76fd106e" referenced
memory at "0x78be7489". The memory could not be "read"'.
If I comment-out/remove the RegularExpressionValidator, IE6 works
"perfectly" - however the password is obviously no longer being
validated.
I've tried looking on the web for similar problems, but can't find
anything. Does anyone have any suggestions why the code might be
causing the crash?
Thanks in advance,
Al
Can anyone help please? I'm using the following code to validate a
password entered by new users in an <asp:Textbox ... />:
<asp:RegularExpressionValidator
ID="RegularPassword"
runat="server"
ControlToValidate="RegisterPassword"
SetFocusOnError="True"
ValidationExpression=".*(?=.{8,})(?=(.*\d){2,})(?=(.*\W){1,}).*"
ErrorMessage="Invalid password (min: 8 chars, including 2 numbers
and 1 non-alpha)."
ToolTip="Invalid password."
CssClass="RegistrationError"
Font-Size="11px">
</asp:RegularExpressionValidator>
(...for info, there is also a RequiredFieldValidator associated with
the same control).
The code works correctly in FireFox 1.5 and 2.0, and also in IE7. When
I try the code in IE6, the validation works for invalid entries (i.e.
it outputs the ErrorMessage text), but if a valid password is entered,
IE6 crashes with the error 'The instruction at "0x76fd106e" referenced
memory at "0x78be7489". The memory could not be "read"'.
If I comment-out/remove the RegularExpressionValidator, IE6 works
"perfectly" - however the password is obviously no longer being
validated.
I've tried looking on the web for similar problems, but can't find
anything. Does anyone have any suggestions why the code might be
causing the crash?
Thanks in advance,
Al