ASP.NET News from Blogger:
RegexLib.com - Recent Patterns
Total News: 428
This Expression will allow at least one small letter, one capital and one numeric digit. And length of the password is minimum of 8 and allowed special chars are pre defined(@\$=!:.#%),special chars a...
This expression can be used to validate any date entered in correct DD-MM-YYYY format. Takes care of Leap Years too.....
Validates that a string represents a javascript number (as defined by ECMAScript 3 Specs): integer (base-10) or floating
point including in the exponential notation. Doesn't match the empty string....
Validate HTM/HTML/ASP/ASPX
e.g. PageName.html...
Validate Filename,PageName,ImageName etc
such as
filename.doc
filename.xls
pagename.aspx
pagename.asp
pagename.htm
pagename.html
Extensions
etc ......
Limits the max number of digits before the decimal point to 10; if decimal point is entered, requires entry of 2 decimal places. Allows for an optional negative sign. This pattern was derived to meet ...
Matches any-length chilean RUT (Rol Unico Tributario) and RUN (RUT (Rol Unico Nacional), with or without dots as thousand separator, and with or without hyphen as verification digit separator. Grab 1s...
A quick and dirty expression for splitting up a generic street address...
Modified URL RegExp that requires (http, https, ftp,gopher,telnet,file|notes,ms-help)://, A nice domain, and a decent file/folder string....
Matches any integer from 0 to 2147483647 (max Integer size for C#, Java, others)...
I got a regex for date time from here, which had some bugs. so i referred a few regex from this site and created a regex which i tested and didnt find any errors. I will check again and update if requ...
Oracle like time stamp with format:
dd.MM.yyyy HH.mm.SS.xxxxxxx
Based on European full proved date format with easy changeable dot separator.
Optimized regular expresion....
Check password containing at least x numbers and y alphabetic. Use look back expression (?= )...
Simple Expression to evaluate a Mexican CURP Code...
This regex matches US phone number formats that I found to be commonly used.
This regex is best used on scanning text. If html is present, strip out the html first....
This Regex Will Remove All Html Tags And Return Simple Plain Text .
For Example In C#.NET :
Regex.Replace(Html, "]*>", string.Empty);...
This Regex chceck an input string for persian unicode character
Note that it not work in javascript
For Example In C#.NET:
Regex.IsMatch(Text, "[\u0600-\u06FF]");...
Capture the information from a SQL Server connection string...
My first REGEX pattern. Matches all alphanumerics + underscore (_) + dot (.)...
if (RadDatePicker1.SelectedDate == System.DateTime.Now.Date)
{
string strconnection;
strconnection = ConfigurationSettings.AppSettings["ConnectionString"].ToString();...
This expression can be use to define the maximum length to a textBox.
U can change the maximum character by replacing the last numeric value that is 10 in my example.
Just change this number to your ...
Needed to verify a currency amount entered has commas and two decimal spaces to the right. This has a range between 1.99 to the tens of millions. If you want to make the decimal side optional, add a q...
You can use this to check the valid file type you have given to the last in the expression
like
^(([a-zA-Z]:)|(\\{2}\w+)\$?)(\\(\w[\w].*))+(.pdf)$
This will accept .pdf only
OR
^(([a-zA-Z]:)|(\\{2}\w+...
This Expression will help you in Validating Multiple e-Mail IDs in a single line seperated by ";"...
This Expression verifies all the valid date in the US Date Format.It also checks the leap year.we can use this expression with or with out the prefix of zero in the date column and month column Eg[01/...
Returns the value from a CSV line....
Very basic, but couldn't find it, so from one Regex noob to another...
Needed to replace quotes around giant SQL INSERT unique numeric field; that was in quotes... In DW, FYI, I replaced with: ($2 $...
This was made to change non-decimal prices at the end of a huge SQL Insert... To use to replace in DW (without quotes) use sub expression like: $2,$4)...
This regex gets the value within an XML Tag. For example, given the following tag: result is here it returns the string "result is here". Replace TAGNAME with your tag name....
Expression to validate currency formatted numbers without the currency symbol...
pattern match for U.S. social security number...
This expression was derived from Mike Cromwell's version, which matches the XSD schema duration built in type as defined by http://www.w3.org/TR/xmlschema-2/#duration. This version adds named capture...
RegEx will match phrases in double-quotes or words separated by spaces. It excludes the double-quotes from matches...
This regular expression can be used to validate a strong password. It will evaluate to true if the following critera are met:
Must be 15 characters in length total
Must contain at least 1 digit
Mus...
This expression matches ICD-10 code...
This Regex is usefull to validate if the text typed will still lead to a valid number for a international input.
Replace , with \. to get an american notation...
This expression validate the add of numbers with or without decimal...
This simple expression is used to validate fractions or UK odds.
It will match integers, allowing 10/1 to be entered as 10, and fractions.
It will not match negative numbers or fractions, spaces or an...
Sometimes I want to store some key value mapped data in xml or text file, and then retrieve them into hashtable in program. Authough this can be done by split the string by comma and colon, and then t...
Use this regex to match urls (including folder, file and querystring) in unstructured text that are not in anchor tags. Replace with $1 to create anchor tags....
With this regex you can find or replace any CSS commentary in your stylesheets in once. Build for use with dreamweaver. Probably works also fine in any other circumstances....
match *** in html,so any other html mark with is just do a little change to this...
first regex put on site.
longitude must>=-180 & <180....
This expression validates most legal dates for a SQL Server 2005 datetime format. It includes checking for leap years. (Written for a default U.S. install, not sure what results would be on versions f...
Tokenize a Javascript document for parsing
each token is a language-token : string, int, float, comment, multiline comment, operator, expression etc. etc....
This finds the SELECT part of a SQL select statement. It does not find the entire FROM statement. That is a different RegEx I will post later....
Valid XML Node or Attribute Names start with a letter , an underscore or a colon (generally avoid using a colon)
The next characters may be letters, digits, underscore, hyphens, periods and colons ...
Filters out VB.NET and VB6.0 comments....
This expression will validates most of the email formats....
Finds title, first name, middle initial, last name, and suffix of a name. Middle names are added to first name. Uses .Net capture group names....
View Other bloggers