none
Regular expression to allow only numbers and numbers range should be from 0 to 99999

    Question

  • Can any one help me in regular expression  to allow only numbers and numbers range should be from  0 to 99999
    Friday, August 19, 2011 5:36 PM

Answers

  •  

    ^[0-9]{1,5}$

     

    OR

     

    (^[0-9][0-9]?[0-9]?[0-9]?[0-9]?$)
     

    You can use this site to make and check your regular expressions online http://www.rubular.com/
    • Edited by Rizwan Qamar Friday, August 19, 2011 6:03 PM Added more helpful material.
    • Marked as answer by tsk238 Friday, August 19, 2011 6:22 PM
    Friday, August 19, 2011 5:56 PM

All replies