ASP.Net Validation controls not working in netscape

S

Srinivasa Raghavan

Hi all,


The Asp.net validation controls are skipping the
validations in netscape.Please suggest a solution for this.



Thanks
Srinivasa Raghavan
 
S

S. Justin Gengo

Srinivasa,

The validation controls are not guaranteed to work clientside in any browser
other than IE. That is why you can also check their validation server side
for the exact reason you are experiencing.

Here's what to do:

Place any code that should only fire if the page is valid in an if/then like
this:

If Page.IsValid Then
'---Your code here.
End If

Now the validators will require a post back to the server, but the code
won't execute unless the page is valid. When an invalid page is returned to
a Netscape browser from the server the validators error messages will
appear.

Sincerely,

--
S. Justin Gengo, MCP
Web Developer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
 
S

Srinivasa Raghavan Sethuraman

Hi

Canu Suggest some other solution apart from validating at server side.



Thanks
Srinivasa Raghavan
 
S

S. Justin Gengo

Sorry, but that's about it.

You could always write your own custom validators for each browser you need
to support and then check for wich browser the client is with
Request.Browser.Browser, but that would be an awful lot of code to write.

There is no guarantee that code will work from one browser to the next. It's
just something we all have to deal with.

--
S. Justin Gengo, MCP
Web Developer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
 

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,780
Messages
2,569,608
Members
45,241
Latest member
Lisa1997

Latest Threads

Top