I have a button connected to a UiProgressView, has only the function to count the clicks on the button ... I need to show the percentage of completion in a UILabel .. Can you tell me which method is better?
To make you understand the function I show you the code of the IBAction
- (IBAction)FFAddCFU:(id)sender {
if (FFVariabileNumerica_CFU >= 30)
return;
FFVariabileNumerica_CFU++ ;
[FFCFULabel setText:[NSString stringWithFormat:@"%d", FFVariabileNumerica_CFU]];
if(FFProgressBar.progress == 0.50 || FFProgressBar.progress == 0.77 ){
[ FFProgressBar setProgress : FFProgressBar.progress +0.25 ];
} else {
if (FFProgressBar.progress > 0.76) {
[ FFProgressBar setProgress : FFProgressBar.progress +0.25 ]; }
}
}