How I Can Design this Form ?
-
I need split text form text box For Example : this pictures http://www.cpestudents.net/upload/up/sharpd.gif[^] please help me
If I understood correctly what you want, try this:
string[] parts = this.txtFullName.Text.Split(' '); this.txtFirstName.Text = parts[0]; this.txtSecondName.Text = parts[1]; this.txtLastName.Text = parts[2];
Of course you'll probably need to do some more validation but that method will work :-D. Ed -
If I understood correctly what you want, try this:
string[] parts = this.txtFullName.Text.Split(' '); this.txtFirstName.Text = parts[0]; this.txtSecondName.Text = parts[1]; this.txtLastName.Text = parts[2];
Of course you'll probably need to do some more validation but that method will work :-D. Ed -
Just remember to think about what would happen if the full name didn't have middle name, or if it had a compound last name, three names, and so on. -- LuisR
Luis Alonso Ramos Intelectix - Chihuahua, Mexico Not much here: My CP Blog!
The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005