• 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
Float value change
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Float value change


  • Subject: Float value change
  • From: Tharindu Madushanka <email@hidden>
  • Date: Tue, 28 Apr 2009 12:36:13 +0530

Hi,
I have float values in my iPhone program, when I type in a textfield and
print it it shows a little different value than what I have typed, I used
printf to see the results. I can't understand why its happening. How can I
resolve this.
For example textfield.floatValue
actual value typed - 44.45
displayed value - 44.459999
Can any one help me on some way to avoid this. Thanks
-Tharindu
_______________________________________________

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: Float value change
      • From: Tharindu Madushanka <email@hidden>
    • Re: Float value change
      • From: Kyle Sluder <email@hidden>
  • Prev by Date: Re: Why is NSString->FSRef so hard?
  • Next by Date: Re: Float value change
  • Previous by thread: Re: Getting Display Names
  • Next by thread: Re: Float value change
  • Index(es):
    • Date
    • Thread