Author: harshalbhakta | Posted on: 7/23/2008 12:58:19 AM | Views : 720

Hi Experts,

I have 4 textboxs and I have written a JS function TrimAll() for all 4 textboxes' "onblur" event. In this function I am trimming the value of the textbox and replacing the original value of the textbox with the trimmed value. Aftre replacing with trimmed value I am calling Page_ClientValidate() function so that I get a rid of regularexpression validator's errormessage.

I know its confusing.. let me explain..

In the email textbox if I write some spaces and then email, the regular expression validator gives error message. At the same time, my JS function TrimAll() trims the email address, so in this case regular expression's error message does NOT disappear, so I have to call Page_ClientValidate() (so that errormessage disappears) . This works fine for Email textbox. But at the same time, another textbox (say firstname) is still empty and its requiredfield validator's errormessage appears (this is because I explicitely ca ...

Go to the complete details ...