Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How does Studio handle rounded numbers?



Here's a summary of my code in a Studio app:

set p to (round (9.85165247269 * 100) rounding up) / 100

log p
--> 9.86

set contents of data cell "something" of data row dataRow of dataSource to p
--> 9.86

set contents of text field "whatever" of window "wherever" to p
--> 9.859999999999999

???

The log and table correctly display the number (p) to 2 decimal places. The text field does not.

MarkB
_______________________________________________
applescript-studio mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-studio
Do not post admin requests to the list. They will be ignored.



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.