Hello,
The problem is quiet trivial. Say suppose i have "Hello friendes{BACK}{BACK}s" in one file. Now when i print the file's contents in textbox it should print "Hello friends"
({BACK} = backspace key). I don't know how to do this. I tried
Code:
stringvariable.Replace("{BACK}","\b");
but it's not working. I even tried this for loop
Code:
while(1 > 0)
{
int intIndex = StringToFormat.IndexOf("{BACK}");
if (intIndex <= -1)
break;
if (intIndex == 0)
StringToFormat = StringToFormat.Remove(0, 6);
else
StringToFormat = StringToFormat.Remove(intIndex - 1, 7);
}
because the user may press several backspaces simultaneously. Please help me!
Thanks in advance