File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes HTML, CSS and JavaScript and the fly likes validation check Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "validation check " Watch "validation check " New topic
Author

validation check

Li Jenny
Ranch Hand

Joined: Apr 19, 2010
Posts: 57
I would like to do a validation check for textbox field.
only let the user input number range or just a number in the following format:

1) 11,12
2)1-10,11-20
if the user input 1 to 10, or other than the above format, then prompt a msg.
Amit Vinod Dali
Ranch Hand

Joined: Apr 14, 2010
Posts: 42
You can use JavaScript RegExp Object. Regular Expression generator
Li Jenny
Ranch Hand

Joined: Apr 19, 2010
Posts: 57
how to use this.?
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Write a regular expression and use it to check the input--what does your regex look like so far?
 
jQuery in Action, 2nd edition
 
subject: validation check