• 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
NSString stringWithFormat woes
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSString stringWithFormat woes


  • Subject: NSString stringWithFormat woes
  • From: Stuart Green <email@hidden>
  • Date: Tue, 8 Apr 2008 20:33:59 +0100

Hi,

I have a string declaration of:

returnString = [NSString stringWithFormat:@"%c-%i-%i-%f", asciiString, firstDouble, secondDouble, thirdDouble];

Which is producing a weird output when used outside of an NSLog.

Examining each parameter in the debugger shows exactly what I want, i.e. an ASCII string, a floored double (no decimals), another floored double (no decimals) and a double with a decimal.

What do I need to do in order to display them correctly in the returnString?

Cheers,

Stu
_______________________________________________

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


  • Follow-Ups:
    • Re: NSString stringWithFormat woes
      • From: "Hamish Allan" <email@hidden>
    • Re: NSString stringWithFormat woes
      • From: Jack Repenning <email@hidden>
    • Re: NSString stringWithFormat woes
      • From: Michael Vannorsdel <email@hidden>
    • Re: NSString stringWithFormat woes
      • From: Randall Meadows <email@hidden>
  • Prev by Date: Core Data for managing subtree?
  • Next by Date: Re: NSString stringWithFormat woes
  • Previous by thread: Re: Core Data for managing subtree?
  • Next by thread: Re: NSString stringWithFormat woes
  • Index(es):
    • Date
    • Thread