If you are not using server controls & validation controls or if you need to validate input from sources other than form fields, such as query string parameters or cookies, you can use the Regex class within the System.Text.RegularExpressions namespace.
To use the Regex class
- Add a using statement to reference the System.Text.RegularExpressions namespace.
Call the IsMatch method of the Regex class, as shown in the following example.
// Instance method: Regex reg = new R...
No comments yet, be the first one to post comment.