adding quotes in string

mfhaque

Registered
if i had a mutable string called myString and using the method appendFormat. how do i add quotes to the string that is bein added.

for instance, [myString appendFormat:mad:"%@",[textBody string]];

i want to add quotes around what ever is put in.
 
It just needs to be escaped with a backslash; using your code:

Code:
[myString appendFormat:@"\"%@\"",[textBody string]];

would put quotes around the result from textBody's string message.
 
Back
Top