regular expression for text box

Posted by Deepakji under ASP.NET on 4/4/2012 | Points: 10 | Views : 1115 | Status : [Member] | Replies : 4
hi , i need a regular expression which need to accept only this format(22,2+2) but not (+2,+++,+2+,222,++2)
means only one '+' that in middle for text box so please let me know its urgent and maximum limit of textbox is 3




Responses

Posted by: Sakthi.Singaravel on: 4/4/2012 [Member] Silver | Points: 25

Up
0
Down
Hi Deepak,

U'r required regex as follows:

[^+,A-z]((\d+(\+\d+)?\,?)+){3}


Regards,
Singaravel M

Deepakji, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sakthi.Singaravel on: 4/4/2012 [Member] Silver | Points: 25

Up
0
Down
Hey Deepak,

The above code is working or not..



Regards,
Singaravel M

Deepakji, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Deepakji on: 4/4/2012 [Member] Starter | Points: 25

Up
0
Down
hi Singaravel M,

thanks for reply but sorry to say that its not working

Deepakji, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sakthi.Singaravel on: 4/4/2012 [Member] Silver | Points: 25

Up
0
Down

can u post ur code...?


Regards,
Singaravel M

Deepakji, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response