Long form issue

  • Thread starter Thread starter VK
  • Start date Start date
V

VK

Hello:

We have a very long form in .Net - issue comes in when a user wants to
submit the form, and due some of error checking we perform, like
required fields left blank the form is not submitted but at the same
time the form doesn't jump to the location where the field is blank
requesting users to fill in, it just stays at the bottom near submit
button instead of jumping to that location.

Unless the user scrolls up the form and sees the error message, he
really doesn't know what the issue would be with the form.

Is there a way to solve this without using Javascript?

many thanks.
 
How about using the HTML anchor tag (<A href="#Fieldn"/>) on each field
label. Then by changing the document.location element in the js you could
jump down to that field label.

Greg H.
 
Without JS, not really, But you could add a Validation Summary to your
page, you'll find it in the toolbox in VS with the other validation
objects.

Set the ShowMessageBox properties to True to display a message, and you
will get an alert box appear on the user screen that will tell them
what the failures were based on the values you place in the
ErrorMessage properties for the validation controls on your page.

Hope this helps.
 
Turn on SmartNavigation

Add this to the page load event

VB code

SmartNavigation = true

Corey
 
Turn on SmartNavigation in the page load event or in the ASPX file

in VB code ...

SmartNavigation = True
 
Be careful when using SmartNavigation as it is very suspectible to causing
unpredictable Jscript failures when not running on localhost, even using IE6.
 
Back
Top