Click here to Skip to main content
13,293,178 members (84,790 online)
Rate this:
Please Sign up or sign in to vote.
See more:
I have search this in Google but not exactly solution of my problems.
Posted 20-Feb-12 20:05pm
Varun Sareen 21-Feb-12 1:14am
Please paste some sample code of yours
krumia 21-Feb-12 1:34am
Your question is vague.

Do you want to do something like this: Your text box has a text "samplesamplesample" and you just want to change it to "sample".
OriginalGriff 21-Feb-12 2:53am
This is not a good question - we cannot work out from that little what you are trying to do.
Remember that we can't see your screen, access your HDD, read your homework instructions, or read your mind.
Use the "Improve question" widget to edit your question and provide better information.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

string SearchFor = "Hi";
string ReplaceWith = "Bye";
textbox1.Text = "Hi, this is your textbox string Hi";
textbox1.Text = textbox1.Text.Replace(SearchFor, ReplaceWith);
/* RESULTS: "Bye, this is your textbox string Bye" */

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy |
Web04 | 2.8.171207.1 | Last Updated 31 Jul 2012
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100