Solved

RegEx decimal validation

Posted on 2013-06-25
6
503 Views
Last Modified: 2013-06-30
Hi,

How can I validate the following format using Regular expression validator?

any decimal value > max 100.

Please help.

ayha
0
Comment
Question by:ayha1999
6 Comments
 
LVL 58

Assisted Solution

by:Gary
Gary earned 30 total points
ID: 39275408
([0-9.-]{1,10}|100)
0
 
LVL 41

Assisted Solution

by:guru_sami
guru_sami earned 30 total points
ID: 39275416
0
 
LVL 4

Assisted Solution

by:ramyajanarthanan
ramyajanarthanan earned 30 total points
ID: 39277597
0
What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

 
LVL 74

Accepted Solution

by:
käµfm³d   👽 earned 60 total points
ID: 39287249
This should work for 0 - 100:

^(?:100(?:\.0+)?|\d{2}(?:\.\d+)?|0?\d(?:\.\d+)?)$

Open in new window

0
 
LVL 7

Author Closing Comment

by:ayha1999
ID: 39288391
Thanks
0
 
LVL 74

Expert Comment

by:käµfm³d 👽
ID: 39288412
I feel the need to point out that GaryC123's suggestion considers entries such as the following to be valid input:

..........
-.-.-.-.
----

Open in new window

0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
ASP.Net to Oracle Connectivity Recently I had to develop an ASP.NET application connecting to an Oracle database.As I am doing it first time ,I had to solve several problems. This article will help to such developers  to develop an ASP.NET client…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now