RegularExpressionValidator new behaviour

  • Thread starter Thread starter Mehdi
  • Start date Start date
M

Mehdi

Hi,

After deploying my asp.net (1.1) to IIS 6, I have noticed that my validation
expressions are not validating the controls (i.e textboxes) on the
client-side any more and round-trips are occuring.


Any ideas why?


Regards


Mehdi
 
Hermit,

Thanks for the reply.

I have asp_client folders such javascripts (if I undrestand you correctly)
on the web root. However I am not using my own javascripts here is an
example:

RegularExpression1.ValidationExpression = "^[0-9a-zA-Z]{5,15}$";
RegularExpression1.ControlToValidate = TextBox1;
RegularExpression1.ErrorMessage = "Please enter a valid text";



Mehdi
 
did you upgrade the framework on the server recently ? i have heard of
instances where the service pack sorted up a few people's apps.

i would suggest you do the following

start >> run >> cmd
cd %windir%\microsoft.net\framework\framework_version
aspnet_regiis.exe -i

That will reinstall the binding of framework with IIS. let me know if that
helps

And yes i understood you correctly. When you use the regularexpression
validators or any validator like requiredfield validator.. it links up to
the js file for validation.
--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
 
Thanks again Hermit,

Unfortuntely I have no control over IIS as I am using a shared server
solution. Can you think of anything alse beside framework upgrade that may
cause this?




Hermit Dave said:
did you upgrade the framework on the server recently ? i have heard of
instances where the service pack sorted up a few people's apps.

i would suggest you do the following

start >> run >> cmd
cd %windir%\microsoft.net\framework\framework_version
aspnet_regiis.exe -i

That will reinstall the binding of framework with IIS. let me know if that
helps

And yes i understood you correctly. When you use the regularexpression
validators or any validator like requiredfield validator.. it links up to
the js file for validation.
--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
Mehdi said:
Hermit,

Thanks for the reply.

I have asp_client folders such javascripts (if I undrestand you
correctly)
on the web root. However I am not using my own javascripts here is an
example:

RegularExpression1.ValidationExpression = "^[0-9a-zA-Z]{5,15}$";
RegularExpression1.ControlToValidate = TextBox1;
RegularExpression1.ErrorMessage = "Please enter a valid text";



Mehdi
 
what i would suggest is browse through the earlier posts on this and the
framework NGs. i am not sure if people have it resolved.

BTW. do you have other validation controls working correctly ?

--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
Mehdi said:
Thanks again Hermit,

Unfortuntely I have no control over IIS as I am using a shared server
solution. Can you think of anything alse beside framework upgrade that may
cause this?




Hermit Dave said:
did you upgrade the framework on the server recently ? i have heard of
instances where the service pack sorted up a few people's apps.

i would suggest you do the following

start >> run >> cmd
cd %windir%\microsoft.net\framework\framework_version
aspnet_regiis.exe -i

That will reinstall the binding of framework with IIS. let me know if that
helps

And yes i understood you correctly. When you use the regularexpression
validators or any validator like requiredfield validator.. it links up to
the js file for validation.
--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
Mehdi said:
Hermit,

Thanks for the reply.

I have asp_client folders such javascripts (if I undrestand you
correctly)
on the web root. However I am not using my own javascripts here is an
example:

RegularExpression1.ValidationExpression = "^[0-9a-zA-Z]{5,15}$";
RegularExpression1.ControlToValidate = TextBox1;
RegularExpression1.ErrorMessage = "Please enter a valid text";



Mehdi
 
All validation controls working ok after round-trip to the server except my
custom javascripts such as:

function ConfirmDelete(source, arguments)
{
if (confirm("Are you sure you wish to delete selected record(s)?"))
{
arguments.IsValid = true;
}
else
{
arguments.IsValid = false;
}
}



Thanks


Mehdi
 
i think you have problems with default validators... you mentioned that its
a shared server. if its with a host then ask them... raise a problem and get
them to look at it. The problem is client side validation. Seems to me that
your server side is just fine. WebUIValidation.js is the thing you are
looking for.

--

Regards,

Hermit Dave
(http://hdave.blogspot.com)
 
I moved the "asp_client" folder in the same level as my virtual folder that
I have access to via ftp and it worked!


Many thanks again

Mehdi
 
Back
Top