Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Form Validation: NinRange

Status
Not open for further replies.

Sensibilium

Programmer
Joined
Apr 6, 2000
Messages
310
Location
GB
Hi,

I'm having serious problems with the Form Validation routine (DW4 Ultradev) on text fields, and I really need to know why it doesn't work properly.

Let's say I set the NinRange from 1 to 300
Numbers: 1-3, 10-13, 20-23, 30-33, 100-103, 110-113 (you can see a pattern
emerging yes?) are all accepted a within the set range...

All other numbers containing 4, 5, 6, 7, 8, or 9 are rejected as outside of
the range...

Madness! Any help would be greatly appreciated, or even a form validation script that works would be nice!

I put this question into the ultradev newsgroup, but no-one bothered answering (up their own ars*s - 'scuse me French) Ahdkaw
"What would you expect from a bunch of monkeys?"
 
Looks to me like the range is for characters/text and not for numbers. You want this to be for numbers.
 
Thanks dpcjsr, but the fact is that it has been set as a number ranging from 1 to 300, the code is automatically created by DW Ultradev not by me.

According to all the dialogs DW shows for my text box, everything is set up correctly, but I will look further and see if I can come up with an answer.

Anyone know the Javascript code for converting to an integer (like CInt() in VBS)?
Ahdkaw
"What would you expect from a bunch of monkeys?"
 
Hi,

Maybe this answer is comming a bit late, but anyway:

I'm using a great validation extention from YAROMAT.

It works fine, just having toubles (with numbers too) insertion a '0'-value. Zero is not accepted as a number. So if you have a solution for this, it's welcome.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top