Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Tools & Utilities

Reply
 
LinkBack Thread Tools Display Modes
Old 07-05-2011, 11:48 AM   #1 (permalink)
Registered Member
 
Join Date: Jul 2011
Posts: 30
cnmeyer1980 is on a distinguished road
Default UIScrollView in a Tab Nav Application

Hi everyone,

I've been trying for ages, searching the web and trying to find a tutorial on how to incorporate a UIScrollView into a tab nav based application.

I have a source file i've put together, but it doesn't seem to work.

Could anyone help if i send the source code?

Many thanks in advance.

Chris
cnmeyer1980 is offline   Reply With Quote
Old 07-10-2011, 01:43 AM   #2 (permalink)
Registered Member
 
Join Date: Jun 2011
Posts: 44
Karl6669 is on a distinguished road
Default

Quote:
Originally Posted by cnmeyer1980 View Post
Hi everyone,

I've been trying for ages, searching the web and trying to find a tutorial on how to incorporate a UIScrollView into a tab nav based application.

I have a source file i've put together, but it doesn't seem to work.

Could anyone help if i send the source code?

Many thanks in advance.

Chris
I've got this working on my app currently. I'm a newbie, but, what I've found is that I have to set the size of the UIScrollView to the size of the visible and usable remaining area of your view (above the tab bar and below the navigation bar (if applicable)) within Interface Builder, then in your viewDidLoad or viewDidAppear method's, set your content size to the scroll size required. If you set your scroll size to larger than your visible/usable area from interface builder, it won't work.

Code:
    [scrollView1 setBackgroundColor:[UIColor clearColor]];
    [scrollView1 setCanCancelContentTouches:NO];
    scrollView1.indicatorStyle = UIScrollViewIndicatorStyleDefault;
    scrollView1.clipsToBounds = YES;        // default is NO, we want to restrict drawing within our scrollview
    scrollView1.scrollEnabled = YES;
    scrollView1.pagingEnabled = NO;
    [scrollView1 setContentSize:CGSizeMake(320.0, 950.0)];
Karl6669 is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 411
11 members and 400 guests
AppleDev, chemistry, Emy, Gi-lo, ipodphone, mistergreen2011, pipposanta, QuantumDoja, Retouchable, SLIC
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,679
Threads: 94,129
Posts: 402,924
Top Poster: BrianSlick (7,990)
Welcome to our newest member, xzoonxoom
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 08:29 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0