NSString to const char
NSString to const char
- Subject: NSString to const char
- From: Micha Fuhrmann <email@hidden>
- Date: Mon, 26 May 2008 15:47:04 +0200
Hi everyone,
in advance sorry for asking... must be very basic, however couldn't
find anything suitable.
I need to pass a const char to a C++ function from an NSString.
However the argument I pass end up as garbage and that's it. Here an
example to illustrate:
NSString* theNsstring = @"étape";
const char* theConstString = [theNsstring
cStringUsingEncoding:NSUnicodeStringEncoding];
In the console theConstString ends up as "\xe9".
Any help very much appreciated
Michael_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden