asp.net mvc - C# regular expression format -
i want allow following 3 digit strings accepted: 083, 084, 085, 086, 087, 088 or 089
at moment i'm using:
[regularexpression("^08\\{1}$", errormessage = "please enter valid 3 digit area code")]
but accepts 081 , 082
i've tried using:
[regularexpression("^08\\[3-9]{1}$", errormessage = "please enter valid 3 digit area code")]
but it's not working me
the regex should
[regularexpression("^08[3-9]$", errormessage = "please enter valid 3 digit area code")]
Comments
Post a Comment