Validation works on one server but not on the other

A

Andrei Pociu

I saw a few people on the web having this problem, yet no solution.
Validation using RequiredFieldValidator works fine on my server, but on some
other server it doesn't do anything. Oh, and I'm using client-side
validation.

Any ideas?
 
J

jongalloway

Sounds like your website on the second server might not have the
aspnet_client files. Are you getting any javascript errors when the
page is displayed?

You can try running the following command on that server to (re)install
the client scripts:
aspnet_regiis -c
The default location for aspnet_regiis.exe is
C:\Windows\Microsoft.NET\Framework\v1.1.4322.
http://msdn.microsoft.com/library/d...ASPNETIISRegistrationToolAspnet_regiisexe.asp

If that doesn't fix it, and you are getting a JS error, see this for
some other ideas:
http://weblogs.asp.net/rosherove/archive/2003/10/06/30652.aspx

- Jon
http://weblogs.asp.net/jgalloway
 
J

jasonkester

Looks like you might be missing some of the .js scripts that the client
validator needs. Normally, the page will protest if you try to use
client validation without them present, but you may just be out of
synch.

On the box that's not working, try:
C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\aspnet_regiis.exe -c

Good luck!

Jason
http://www.expatsoftware.com/
 
A

Andrei Pociu

No, there is no JavaScript error.

Thanks a million jongalloway and jasonkester, I have a feeling
"aspnet_regiis -c" will fix it :)

Yours,
Andrei Pociu
 
A

Alan Silver

Do you know if there is a way to install these files on one web site
only? We have a web server with loads of sites, most of them Classic
ASP, and we would like to install the ASP.NET client files on the (so
far few) ASP.NET sites only.

Running the aspner_regiis utility copies the files to every site on the
server.

On the production server, all sites are under one folder, ie we have one
at F:\WebFolders\SiteOne and another at F:\WebFolders\SiteTwo and so on.
On the development machine they are all over the place. Don't know if
this makes a difference.

TIA
 
J

Juan T. Llibre

Using the command-line and aspnet_regiis,
you can specify the virtual directory(ies)
into which to install the client scripts.

Just run aspnet_regiis without a parameter,
and you'll get the syntax to do that.

IIRC, it's -sn <path>
i.e. :
aspnet_regiis.exe -sn W3SVC/1/ROOT/YourApp

aspnet_regiis.exe -lk will give you a list of all
directories where ASP.NET is currently installed.

[ In case you screw up, and have to use
aspnet_regiis.exe -k to remove it... ;-) ]
 
A

Alan Silver

Thanks Juan
Using the command-line and aspnet_regiis,
you can specify the virtual directory(ies)
into which to install the client scripts.

Just run aspnet_regiis without a parameter,
and you'll get the syntax to do that.

IIRC, it's -sn <path>
i.e. :
aspnet_regiis.exe -sn W3SVC/1/ROOT/YourApp

aspnet_regiis.exe -lk will give you a list of all
directories where ASP.NET is currently installed.

[ In case you screw up, and have to use
aspnet_regiis.exe -k to remove it... ;-) ]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,534
Members
45,008
Latest member
Rahul737

Latest Threads

Top