2
shouts

Using the Regex Class ASP.Net

posted by rajiivrajiiv 271 days, 7 hours, 39 minutes ago
Saturday, June 20, 2009 9:44:18 AM GMT

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

  1. Add a using statement to reference the System.Text.RegularExpressions namespace.
  2. Call the IsMatch method of the Regex class, as shown in the following example.

    // Instance method: Regex reg = new R...

category: ASP.NET | clicked: 8 | | source: 24x7aspnet.blogspot.com | show counter code
tags: ASP.NET, C#, Regex, Regex class, Regular expressions

No comments yet, be the first one to post comment.

To post your comment please login or signup