This is on a sidenote to my previous question about ratingview
I have this code:
[starView displayRating:1.5];
...however, I want it to be changed according to this:
-(void)ratingChanged:(float)newRating {
ratingLabel.text = [NSString stringWithFormat:@"Rating is: %1.1f", newRating];
//....
How can I make it displayRating: newString
...
Can anyone show me how to do this please?
Update
Update i have this code in place from what ive seen from your instructions (without the labels those are irrevelant)
-(void)viewDidLoad {
NSUserDefaults *defaults=[NSUserDefaults standardUserDefaults];
NSLog(@"Initializing rating view");
[starView setImagesDeselected:@"0.png" partlySelected:@"1.png" fullSelected:@"2.png" andDelegate:self];
[starView displayRating:[[defaults floatForKey:@"Rating"] stringValue]]; }
however i am getting an error message incompatible type for argument 1 of display rating and cannot convert to pointer type errors while building...