• 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: convert int to NSString (Newbie)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: convert int to NSString (Newbie)


  • Subject: Re: convert int to NSString (Newbie)
  • From: Evan Schoenberg <email@hidden>
  • Date: Mon, 21 Feb 2005 08:21:56 -0600

Can't resist...

How about:

char buf[MAX_INT];
itoa (theInt, buf, 10);
[NSString stringWithUTF8String:buf];

-Evan

On Feb 21, 2005, at 5:52 AM, M. Uli Kusterer wrote:

At 9:50 Uhr +0100 21.02.2005, Geert B. Clemmensen wrote:
On 21. feb 2005, at 8.01, Daniel Child wrote:

Is there a simple way to convert an int into an NSString?

Many ways and [NSString stringWithFormat:@"%d", intValue] is one of them.

[[NSNumber numberWithInt: theInt] stringValue] is another one.

 This is fun! :-)
--
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


_______________________________________________ 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
References: 
 >convert int to NSString (Newbie) (From: Daniel Child <email@hidden>)
 >Re: convert int to NSString (Newbie) (From: "Geert B. Clemmensen" <email@hidden>)
 >Re: convert int to NSString (Newbie) (From: "M. Uli Kusterer" <email@hidden>)

  • Prev by Date: Automatic key view handling
  • Next by Date: Re: Automatic key view handling
  • Previous by thread: Re: convert int to NSString (Newbie)
  • Next by thread: Re: convert int to NSString (Newbie)
  • Index(es):
    • Date
    • Thread