Hi everyone,
I would like to know how to refresh a view?
In my SecondView has accelerometer objects and also have some removeFromSuperview, and when I enter the SecondView from MainView again, the removeFromSuperview objects are not there anymore. I need a refresh thing to make all the objects start all over again on SecondView.
code in .h file:
code in .m file:
I added the reloadData, but it shows the warning: "SecondView" may not respond to "+reloadData"
Hope anyone can help, really thank you.
I would like to know how to refresh a view?
In my SecondView has accelerometer objects and also have some removeFromSuperview, and when I enter the SecondView from MainView again, the removeFromSuperview objects are not there anymore. I need a refresh thing to make all the objects start all over again on SecondView.
code in .h file:
Code:
@interface SecondView : UIViewController <UIAccelerometerDelegate> {
......................
}
code in .m file:
Code:
- (IBAction)done {
[self.parentViewController dismissModalViewControllerAnimated:YES];
[B][SecondView reloadData];[/B]
}
I added the reloadData, but it shows the warning: "SecondView" may not respond to "+reloadData"
Hope anyone can help, really thank you.
Last edited: