Hi I want to convert the NSString into Byte array.
if I have string like \"Hello\" then it convert into byte like this {65,23,56,56,56}.
thanks
Use -[NSString UTF8String]
which returns const char*
. Read the reference.
A general tip: if you want to find if a class has a method which does something, look up the official reference! I mean, on the web, there's not only Stack Overflow, but the API provider's (i.e. Apple's or Microsoft's) official documentations!