RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Regular Expression Details

Title Test Find Pattern Title
Expression
^\$?(\d{1,3},?(\d{3},?)*\d{3}(\.\d{1,3})?|\d{1,3}(\.\d{2})?)$
Description
Expression to handle US currency entry in .NET. Handy for regular expression validation controls where the user can be entering in a currancy value but you can't control explict entry values. Will accept a wide variety of values that can be easy cast to a double via the CDbl function. Expression is also compatible with default US string format for currency.
Matches
10000 | 10,000 | $1,000.00
Non-Matches
0.002 | x.0
Author Rating: Not yet rated. brent stineman
Source
Your Rating
Bad Good

Enter New Comment

Title

Name

Comment

Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Title: Bug
Name: Tester
Date: 10/22/2003 10:27:02 AM
Comment:
i found, that the number $12345,123.123 is pass for this form, but the number 123.123 or 12.123 or 3.123


Title: Rev
Name: Pickles
Date: 6/28/2003 10:33:47 AM
Comment:
Seemed to work fine


Copyright © 2001-2024, RegexAdvice.com | ASP.NET Tutorials