Label displays an incorrect value
I have this code:
In .h file:
@interface ViewController : UIViewController
{
float cost9;
}
In .m file:
costBonus9 = 123456789;
NSNumber *numbercost9 = [NSNumber numberWithFloat:costBonus9];
NSString *formatcost9 = [formattercost stringFromNumber:numbercost9];
Label9.text = formatcost9;
But Label9 displays "123456792".
What's the problem?
No comments:
Post a Comment