Please do not post the same thing multiple times. The board software automatically flags certain posts as needing moderator attention. This happens the most often for new users. I'm pretty sure this is made clear at the time you attempt to post. Posting the same thing over and over again just makes that many more posts the moderators have to weed through later. This makes us sad. Don't make us sad. If your post/thread doesn't appear, just wait a while. Don't post it again. If it hasn't shown up by the next day, then you can try again. I normally go through posts in the mornings, and try to check a few times throughout the day, but I'm not here 24/7. There will typically be a significant delay before posts are approved. Just be patient.
Help| I want to edit a NSString.
Hi how can i edit an NSString ?
i want the app to edit a part of the text automatically.
example:
if I get in the string: "Hello world" i want the app automatically edit the text and replace the "world" to "everyone".
more example:
if the string is: "i love world" ---> "i love Everyone"
if the string is: "1234 world 5678" ---> "1234 Everyone 5678"
how can i do this ??
0 •
Replies
There's a section titled "Replacing Substrings" with methods that do exactly that. Almost, NSStrings are immutable so you're really creating new strings. If you really want to modify an existing object you'll have to use NSMutableString.
- Spam
- Abuse
- Troll
0 • Off Topic Insightful Disagree Dislike Like Awesome- Spam
- Abuse
- Troll
0 • Off Topic Insightful Disagree Dislike Like Awesome