I have an app which is like reading a book, and while reading if user hit home button on iPhone, and again reopen the app , it should open on the same page in which user was previously, i have got x position for all the page, since book is in vertical scrolling. plz let me know where to implement the information.
-(void)scrollViewDidEndDecelerating:(UIScrollView *)_scrollView {
CGPoint p = _scrollView.contentOffset;
NSLog(@"x = %f",p.x);
AppDelegate_iPhone *delegate = [[UIApplication sharedApplication] delegate];
delegate.dataValue = p.x;
}
You can use NSUserDefaults to save state information.
to retrieve saved state