• 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
NSNumberFormatter: Display INT as decimal
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSNumberFormatter: Display INT as decimal


  • Subject: NSNumberFormatter: Display INT as decimal
  • From: Steven Hamilton <email@hidden>
  • Date: Mon, 3 Nov 2008 19:58:20 +1000

Hi Folks,
Following on from my previous query regarding decimals and floats, I've decided to refactor my code to maintain a base component of any currency in use gnucash stylee. This means all values are kept as INT for accuracy. However, I wish to display the "cent" amounts as dollars which means banging a decimal point in 2 digits from the right. Can NSNumberformatter be made to do this? Display an INT value to make it look like a decimal without actually turning it into an NSDecimal as such? And also, accept input that looks like a decimal but is stored as an INT?
_______________________________________________


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


  • Prev by Date: Re: Use of cURL and OpenSSL versus CF and NS Classes
  • Next by Date: Re: Lack of Initializers or Factory Methods
  • Previous by thread: Re: Use of cURL and OpenSSL versus CF and NS Classes
  • Next by thread: FW: NSNumberFormatter: Display INT as decimal
  • Index(es):
    • Date
    • Thread