473,513 Members | 2,456 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Validation Controls stop working!

Dear All

I have a Windows 2003 Server with IIS6 where the validation controls on
ASP.Net pages no longer work.

I believe it to be specific to the server as if I create an ASP.Net page on
the IIS Server of my Workstation (Win XP) with a text box, button and
required field validator, this works fine. If I create the same page on the
IIS6 Windows 2003 Server the validation control doesn't stop the post. I've
tried different browsers and JavaScript is on!

For example if I have a number of panels in which the visibility is turned
on or off by the button click event this event still fires. The visibility
on the panel where the validation control is situated turns off and the
error message is never seen. If I leave the visibility on that panel alone
then I see the error message but the click event still fires (not much use).

Looking at the code I presume that the validation control generates some
JavaScript which should be called on post. Is it possible that the Win 2003
Server isn't generating that JavaScript?

Anybody come across this before?

Any suggestions?

Martyn Fewtrell
mf*******@networkclub.co.uk
Nov 18 '05 #1
2 3978
You are correct in what you are saying but this is not the problem!

If you have a form split into two parts - lets say contact details on the
first panel and then the enquiry details on the second panel.

Initially the first panel is set to visible = True and then the second panel
to visible = False. When you click the Next button the validation controls
should validate the controls on the first panel before running the click
event on the button i.e. it should stop the click event turning off the
first panel and then turning on the second panel.

This works perfectly on my workstation but if I copy the code onto the
server the validation controls just don't work and the click event still
fires changing the visibility on the forms. However if I disable the
visibility on the first panel i.e. instead of turning one off and one on, I
just turn the second one on then the error messages can be seen on the first
panel.

I therefore conclude that the error messages on the validator controls are
working but the validation control is failing to stop the click event from
following through.

I hope this explains it better!
"Fernando Hunth" <Fe***********@discussions.microsoft.com> wrote in message
news:8F**********************************@microsof t.com...
Martyn:

I think that it is not a 2003 Problem.
It is true that .Net generates javascript for validations, but if you have
these controls at a container that you set it to Invisible, these controls
never are rendered and sent to client, because when you set the visibility
property on a control, it is never rendered.

Another cause of some validation control does not work is that you have a
script error, that causes that the javascript that is generated by .Net ,
does not run.

Hope this helps.

"Martyn Fewtrell" wrote:
Dear All

I have a Windows 2003 Server with IIS6 where the validation controls on
ASP.Net pages no longer work.

I believe it to be specific to the server as if I create an ASP.Net page on the IIS Server of my Workstation (Win XP) with a text box, button and
required field validator, this works fine. If I create the same page on the IIS6 Windows 2003 Server the validation control doesn't stop the post. I've tried different browsers and JavaScript is on!

For example if I have a number of panels in which the visibility is turned on or off by the button click event this event still fires. The visibility on the panel where the validation control is situated turns off and the
error message is never seen. If I leave the visibility on that panel alone then I see the error message but the click event still fires (not much use).
Looking at the code I presume that the validation control generates some
JavaScript which should be called on post. Is it possible that the Win 2003 Server isn't generating that JavaScript?

Anybody come across this before?

Any suggestions?

Martyn Fewtrell
mf*******@networkclub.co.uk

Nov 18 '05 #2
Two suggestions:

1. Make sure the validation script file, WebUIValidation.js, is installed
and associated with the version of ASP.NET running on that server. The
easiest way to do this is by running this command on that server:

[windows]\microsoft.net\framework\[version]\aspnet_regiis.exe -c

2. In one release of ASP.NET 1.1, there is a bug in the client-side code
that submits the page and causes the page it incorrectly submit. I don't
remember if it always blocks or always allows. Microsoft has put out some
hot fixes to ASP.NET 1.1. Look for them at msdn.microsoft.com to find the
one involved.

--- Peter Blum
www.PeterBlum.com
Email: PL****@PeterBlum.com
Creator of "Professional Validation And More" at
http://www.peterblum.com/vam/home.aspx

"Martyn Fewtrell" <mf*******@networkclub.co.uk> wrote in message
news:Ob**************@tk2msftngp13.phx.gbl...
You are correct in what you are saying but this is not the problem!

If you have a form split into two parts - lets say contact details on the
first panel and then the enquiry details on the second panel.

Initially the first panel is set to visible = True and then the second panel to visible = False. When you click the Next button the validation controls
should validate the controls on the first panel before running the click
event on the button i.e. it should stop the click event turning off the
first panel and then turning on the second panel.

This works perfectly on my workstation but if I copy the code onto the
server the validation controls just don't work and the click event still
fires changing the visibility on the forms. However if I disable the
visibility on the first panel i.e. instead of turning one off and one on, I just turn the second one on then the error messages can be seen on the first panel.

I therefore conclude that the error messages on the validator controls are
working but the validation control is failing to stop the click event from
following through.

I hope this explains it better!
"Fernando Hunth" <Fe***********@discussions.microsoft.com> wrote in message news:8F**********************************@microsof t.com...
Martyn:

I think that it is not a 2003 Problem.
It is true that .Net generates javascript for validations, but if you have
these controls at a container that you set it to Invisible, these controls never are rendered and sent to client, because when you set the visibility property on a control, it is never rendered.

Another cause of some validation control does not work is that you have a script error, that causes that the javascript that is generated by .Net , does not run.

Hope this helps.

"Martyn Fewtrell" wrote:
Dear All

I have a Windows 2003 Server with IIS6 where the validation controls on ASP.Net pages no longer work.

I believe it to be specific to the server as if I create an ASP.Net page
on the IIS Server of my Workstation (Win XP) with a text box, button and
required field validator, this works fine. If I create the same page
on
the IIS6 Windows 2003 Server the validation control doesn't stop the post. I've tried different browsers and JavaScript is on!

For example if I have a number of panels in which the visibility is turned on or off by the button click event this event still fires. The visibility on the panel where the validation control is situated turns off and
the error message is never seen. If I leave the visibility on that panel

alone then I see the error message but the click event still fires (not much use).
Looking at the code I presume that the validation control generates some JavaScript which should be called on post. Is it possible that the Win 2003 Server isn't generating that JavaScript?

Anybody come across this before?

Any suggestions?

Martyn Fewtrell
mf*******@networkclub.co.uk


Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
4490
by: earwicker | last post by:
I recently deployed a web application which contains a user registration form with the usual fields: name, address, email, password, etc. Each of the TextBoxes uses a validation control to verify...
1
1429
by: Simon | last post by:
Hi, Has anyone experienced the problem where validation controls stop a previously working page from submitting. Sometimes, when I move between my work machine and my home machine validation...
4
4208
by: AIM48 | last post by:
Hi. We have a framework that we work with for our project. So far we have had very good success – basically the frame work wraps many day to day tasks so that they are all included in the...
2
6689
by: Tim Frawley | last post by:
Source code attached indicates my problem with validation and a button bar save button. Fill the Textbox with some text then tab off the control. The message box will display the text in the...
2
4492
by: dustbort | last post by:
I recently had a problem where my required field validator stopped working. But, the page still posted back and tried to insert a record into the database without performing server-side validation....
1
1817
by: Rajani | last post by:
Hi, I have designed a form which process database Insert, edit and Delete(datagrid). I input userid,password and privilege in textboxes which has validation controls to verify data keyed in....
2
1802
by: Rajani | last post by:
Hi, I have designed a form which process database Insert, edit and Delete(datagrid). I input userid,password and privilege in textboxes which has validation controls to verify data keyed in....
0
1696
by: dhurwitz | last post by:
Hi, In my ASP.NET 2.0 web app, I have a user control, ucBinEdges, with several text boxes. The user control has several validation controls validating the Text of these text boxes -...
3
2162
by: mark4asp | last post by:
How can I stop my Calendar control from firing the form validation events? I have a form containing several controls which have several validation controls each. One control is a TextBox...
0
7260
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7160
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7384
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7537
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7525
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5685
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5086
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4746
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
1
799
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.