Count of characters
#1

i am trying to execute a db update but when i try it, i get an error because name looks like this

 

Manual for making Heros necklace

so the problem is that appear so much . then i have coded this to execute command:

 

 

if (items.description.Contains(" "))
                    {
                        sb.Append(items[i].description);[/i]
[i]                        indice = items[/i][i][i].description.IndexOf(" ");[/i][/i]
[i][i]                        sb.Insert(indice, \\);[/i][/i]
[i][i]                        items[/i][/i][i][i][i].description = sb.ToString();[/i][/i][/i]
[i][i][i]                    }  [/i][/i][/i]
[i][i][i]                    record = ...[/i][/i][/i]

[i][i][i]and this looks like this:[/i][/i][/i]

[i][i][i] [/i][/i][/i]

[i][i][i]Manual for making Hero\s necklace[/i][/i][/i]

[i][i][i]so that is what i wanted but when name has more than one i still have problems, so i would like you help me knowing how to code this to test how much are there and then, inset a \ before all .[/i][/i][/i]

[i][i][i] [/i][/i][/i]

[i][i][i]thanks in advance.[/i][/i][/i]



Messages In This Thread
[No subject] - by soryjero - 07-19-2013, 07:06 PM
[No subject] - by someone - 07-20-2013, 10:39 AM
[No subject] - by soryjero - 07-20-2013, 12:33 PM
[No subject] - by Nymphetamine - 07-20-2013, 12:45 PM
[No subject] - by soryjero - 07-20-2013, 01:36 PM
[No subject] - by Nymphetamine - 07-20-2013, 01:37 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)