Creating validation expression

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Niluka
    New Member
    • Dec 2010
    • 1

    Creating validation expression

    Hi,
    I'm using 3 text box controls in asp.net.
    I want to validate the each text input to this control.
    I want to give only following characters for 3 text boxes
    text box 1 = (/\|"
    text box 2 = .,:;
    text box 3 "|/\)

    How to validate this?
    Which validateion control Do i have to use?
    how to create validatation expressions for this?
    Do you know tool or website to create validation expressios for any characters?

    Thanks

    Niluka
  • GaryTexmo
    Recognized Expert Top Contributor
    • Jul 2009
    • 1501

    #2
    Hi there. I've found this website absolutely awesome for working with regular expressions, which can be used for validation. It helps you build and test them.

    RegExr is an online tool to learn, build, & test Regular Expressions (RegEx / RegExp).


    As for how to validate, you can use a regular expression to validate. You can do this in one of the validate events on a textbox, at which point you can cancel the event if validation isn't met.

    Regex Class

    Comment

    Working...