Results 1 to 3 of 3

Thread: Validating a Textbox whose text is REGEX

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 2004
    Location
    Sydney
    Posts
    51

    Validating a Textbox whose text is REGEX

    I have a textbox whose text is Regular expressions. i want to validate the regular expression (check if it is valid REGEX)before I use it.
    how do I do it?

  2. #2
    Frenzied Member <ABX's Avatar
    Join Date
    Jul 2002
    Location
    Canada eh...
    Posts
    1,622

    Re: Validating a Textbox whose text is REGEX

    Unless you want to write your own vaildator... your probably going to be stuck with trying to use it and handling the exception that is thrown if the RegEx is Invalid.
    Tips:
    • Google is your friend! Search before posting!
    • Name your thread appropriately... "I Need Help" doesn't cut it!
    • Always post your code!!!! We can't read your mind!!! (well, at least most of us!)
    • Allways Include the Name and Line of the Exception (if one is occuring!)
    • If it is relevant state the version of Visual Studio/.Net Framwork you are using (2002/2003/2005)


    If you think I was helpful, rate my post
    IRC Contact: Rizon/xous ChakraNET/xous Freenode/xous

  3. #3
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Validating a Textbox whose text is REGEX

    Sounds like you should get on the net and download one of the many validated text boxes that have already been created. Why reinvent the wheel when so many others already have? There may well be one in the code bank here, otherwise try the Code Project. I'm sure there are a squillion others as well.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width