Validation Expression for Field Validator
======================================
1. Multiple E-Mail Validation [ Separated by Semicolon ';' ] ( For Regular Expression Validator )
^(([a-zA-Z0-9_\-\.]+)@([a-zA-Z0-9_\-\.]+)\.([a-zA-Z]{2,5}){1,25})+
([;.](([a-zA-Z0-9_\-\.]+)@([a-zA-Z0-9_\-\.]+)\.([a-zA-Z]{2,5}){1,25})+)*$
2. Multiple E-Mail Validation ( For Regular Expression Validator )
\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*([,;]\s*\w+([-+.]\w+)*@\w+
([-.]\w+)*\.\w+([-.]\w+)*)*
3. File Exteansion Validator ( For Regular Expression Validator )
^(([a-zA-Z]:)|(\\{2}\w+)\$?)(\\(\w[\w].*))+(.jpg|.jpeg|.gif|.bmp|.tif|.png)$
4. Validate only Numeric Fields. ( For Regular Expression Validator )
^([0-9]{1,})$
5. Price / Amount Validation ( For Regular Expression Validator )
[0-9]{0,3}\.{0,1}[0-9]{0,2}
(^\d*\.?\d*[0-9]+\d*$)|(^[0-9]+\d*\.\d*$)
^\d+(?:\.\d{0,2})?$
(^\d*\.\d{2}$)
6. Wesite Address Validation ( For Regular Expression Validator )
(http|ftp|https):\/\/[\w\-_]+(\.[\w\-_]+)+([\w\-\.,@?^=%&:/~\+#]*[\w\-\@?^=%&/~\+#])?
Monday, August 10, 2009
Use Validation Expression of Field Validators in Asp.Net
Labels:
Asp .Net,
Field Validator,
Validation Expression,
Validations
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment