![]() |
|
[.NET] [TuT] Using .Replace and .Insert [VB.NET] - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [.NET] [TuT] Using .Replace and .Insert [VB.NET] (/showthread.php?tid=208587) Pages: Pages
1
2
|
[TuT] Using .Replace and .Insert [VB.NET] - iRtehLeet™ - Dec 18, 2009 Hello all, this is my small tutorial on how to use .Replace and .Insert in VB.net. .Replace What .Replace does is it will replace whatever text you have chosen with the text you choose, lets look at an example code. Spoiler (Click to View) .Insert .Insert is really useful. What it does is, goes to the indexed number in the text/string that you told it to, and then inserts some text/string there. Let me give you an example. My string = "Hello1234", in Hello1234 I want to insert "World" after "Hello". So I figure out the index number in which the word Hello ends.. to do this we count (INCLUDE 0)... H=0 e=1 l=2 l=3 o=4 1=5, so our index number is 5 (the number we want our word to start), and we want to insert the word "World" so we write "World". See the example below: Spoiler (Click to View) I hope this taught you all a little bit and this is mostly for the noobs out there. Thanks for reading 👍 * - newbie223 - Dec 18, 2009 ok i see but wads the great use? to replace a passworD? * - iRtehLeet™ - Dec 18, 2009 Well there are a lot of uses.. I just haven't figured them out yet, maybe someone else will before me I'm sure I may use them in the future. * - newbie223 - Dec 18, 2009 oni thing i can thing of is make a simple password crypter example password = iRahteh replace h with (010) replace a wit [lol] den password = iR[lol](010)te(010) * - Sikandar - Dec 18, 2009 thankz dude...this will come in handy next time..:) * - iRtehLeet™ - Dec 18, 2009 (Dec 18, 2009 11:26 PM)newbie223 Wrote: oni thing i can thing of is make a simple password crypter example Yeah, would be pretty cool * - Jeff. - Dec 19, 2009 Nice share ( rlly dont see any use yet but thnx) :D:D:D:D:D * - [Eprouvez] - Dec 19, 2009 Pretty easy one, but ?I've been coding for about a year, and never come across the Insert function. So, thank you 🤝 * - The End Gamer - Dec 19, 2009 Great Tutorial This Will Come in Handy For Some Of VB.NET Coderz =) * - iRtehLeet™ - Dec 19, 2009 (Dec 19, 2009 03:13 AM)Eprouvez Wrote: Pretty easy one, but ?I've been coding for about a year, and never come across the Insert function. Yep I just came across it as well and decided to share it. 😁 * - Estemarilix - Dec 19, 2009 Thanks man this is nice share, hope it helps lots of newbs out there, and maybe turn a few skidies into pro hackers one day xD. * - TheOneEyeDude - Dec 20, 2009 Thanks u 4 this thing * - ubbelol - Jul 6, 2011 (Jul 6, 2011 02:47 AM)Szoki333 Wrote: If pic = false then GG ing a 2 year old thread with a completely useless post. 🤦♂ * - KingCobraXD - Jul 6, 2011 Wow. Rare chance. I haven't seen iRtehLeet, Sikandar, and newbie223 for a while. BTW, nice post. =) EDIT: Nvmd. This is an old thread. -.-'' * - ShadowHelper - Jul 6, 2011 .Replace is very useful. A lot of my programs use it and without it my youtube account creator wouldn't work very well :P |