Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1093671
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T23:51:32+00:00 2026-05-16T23:51:32+00:00

I found an example of a paging UIScrollView in Apple’s developer docs and it’s

  • 0

I found an example of a paging UIScrollView in Apple’s developer docs and it’s just what I want for my application. I have a main view with a “Help” button that I want to present a view that users can page through to see all the help topics. The sample is at:

https://developer.apple.com/library/ios/#documentation/WindowsViews/Conceptual/UIScrollView_pg/ScrollViewPagingMode/ScrollViewPagingMode.html%23//apple_ref/doc/uid/TP40008179-CH3-SW1

And it works as advertised, but, as with so many of Apple’s examples, they do all kinds of code right in the AppDelegate. I have my own AppDelegate, but then I have a NavigationController with a RootView that has this “Help” button on it. I can’t seem to get the example code integrated into my own and have it work. I’m pretty sure I can’t put the code they have in their AppDelegate in my own, but how to set it up eludes me.

Can someone point me to an example where they do what I’m talking about?

EDIT: I was able to create a new project and get it to work like Apple’s by moving all the AppDelegate methods into the UIViewController that the template supplied and creating a new ContentPage UIViewController to hold the content. It can scroll from page to page, so I think I can insert this code into my other project ok.

I replaced the applicationDidFinishLaunching with an equivalent viewDidLoad and got rid of the AppDelegate stuff dealing with window and such. Then I changed Apple’s initWithPageNumber: method to refer to my help pages rather than just creating instances of their generic views.

- (id)initWithPageNumber:(int)page {
    NSLog(@"--initWithPageNumber:ContentPage");
    if (self = [super initWithNibName:[NSString stringWithFormat:@"HelpPage%d", page] bundle:nil]) {
        pageNumber = page;
    }
    return self;
}

Thanks for the help – sometimes it’s good just to have someone tell you it can be done to keep going!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T23:51:33+00:00Added an answer on May 16, 2026 at 11:51 pm

    In the sample code, the applicationDidFinishLaunching: method sets up the UIScrollView (and a UIPageControl, but let’s ignore that for now) and then “loads” the first two pages. “Loading” a page consists of loading that page’s view controller into memory and caching it. It then adds that controller’s view as a subview to the UIScrollView offset with an appropriate x based on what “page number” it is. You should be able to do all that in your viewDidLoad.

    If you have a blank view when your view controller’s view is shown, then you haven’t added the subview correctly to your UIScrollView. Depending on what exactly you changed, that could be some combination of (a) not getting the x offset correct, (b) not setting the frame correctly, or (c) not adding it as a subview correctly.

    If you post some of your own code we might be able to shed some light on the problem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have found the example of using the local sockets . The code from
I found an example of lazy loading, and I believe I have implemented it
I found this nice example of doing paging in SQL Server, however, I need
I just started using JSON and found this example from http://imdbapi.com/ : <script type=text/javascript>
I found example from SUN site (http://java.sun.com/developer/technicalArticles/Programming/compression/), but it returns BufferedOutputStream. But I would
I've found a flex paging example I'd like to get working, but can't seem
I still haven`t found any example of sorting implementation through paging in ASP.NET MVC
I found an example of linear regression: http://docs.scipy.org/doc/numpy/reference/generated/numpy.linalg.lstsq.html#numpy.linalg.lstsq x = np.array([0, 1, 2, 3])
I found example of history.pushState() through stackoverflow but I don't understand what each thing
I found an example here to create a select list with optgroups using KnockoutJS.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.