how to split the numeric data?

Posted by Dhivakar under Regular Expressions on 2/7/2011 | Points: 10 | Views : 1824 | Status : [Member] | Replies : 2
hi guys..
i want to get the phone no(10 digits) from data base...then i want to to split the phone into 3 parts..then i hav to list into 3 textboxes..hw to do this....
plz help me...

Dhivakar.M


Responses

Posted by: SheoNarayan on: 2/7/2011 [Administrator] HonoraryPlatinum | Points: 25

Up
0
Down
Hi Dhivakar,

You can use C# Substring function to do this, read through this thread that has code snippet that will help you doing this http://www.dotnetfunda.com/forums/thread3082-how-to-split-the-data-.aspx.

Thanks!


Regards,
Sheo Narayan
http://www.dotnetfunda.com

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

Posted by: Karthikanbarasan on: 2/7/2011 [Member] [Moderator] [Microsoft_MVP] [MVP] Silver | Points: 25

Up
0
Down
Hi,

two things you can do, in DB itself split the Phone number using the SPLIT function and pass as 3 different values to the front end. else get the phone number in single string and then split using the sting split funtions in C# itslef.

Thanks
Karthik
www.f5Debug.net

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

Login to post response