How to make regular expression for this in c#? [closed]
I have a expression, i need to validate. I wanna do it using regular expression. Please help.
AAsswwww-11233 (First 2 char are static - then any alphabets only - then hyphen - then only digits.
try
var regex = new Regex(@"^AA[a-zA-Z]+-[0-9]+$");
@"^AA[A-Za-z]+[-]\d+$"
Learn How to Use and Get The Most out of Regular Expressions
精彩评论