• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: trouble getting c-chars from NSString
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: trouble getting c-chars from NSString


  • Subject: Re: trouble getting c-chars from NSString
  • From: "M. Uli Kusterer" <email@hidden>
  • Date: Thu, 31 Mar 2005 16:21:53 +0200

At 16:48 Uhr -1000 30.03.2005, Daniel Child wrote:
Sorry, I am a newbie and I only did a tiny bit of C, so this question is pretty basic. I am trying to convert an NSString to a C-String so that I can remove certain characters. Somehow I don't seem to be able to get the cString returned from the [NSString cString] method to be assigned to a character array.

You're aware that you don't need to use a C string, right? You can just use an NSMutableString and characterAtIndex: to do the work. That will also take care of international characters that might not fit in a C string, which you'd otherwise lose.
--
Cheers,
M. Uli Kusterer
------------------------------------------------------------
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden
  • Follow-Ups:
    • Re: trouble getting c-chars from NSString
      • From: Jim Hamilton <email@hidden>
References: 
 >trouble getting c-chars from NSString (From: Daniel Child <email@hidden>)

  • Prev by Date: Re: Nested sheets
  • Next by Date: Re: NSTimer not firing if date changed in Sys Prefs
  • Previous by thread: Re: trouble getting c-chars from NSString
  • Next by thread: Re: trouble getting c-chars from NSString
  • Index(es):
    • Date
    • Thread