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 12-06-2011, 05:20 AM   #1 (permalink)
User Interface expert
 
_Mac's Avatar
 
Join Date: May 2009
Location: Sweden
Posts: 141
_Mac is on a distinguished road
Question Storyboard: How set the contentSize of scroll view?

Is it even possible to do this directly in Storyboard/IB? Or do I have to write a VC-class just to set this?

Background;
I've got in a lot of content into a ScrollView and edit it directly within Storyboard (misq UI-items like images, text, buttons etc aprx 1200px hight in total). But I can't get it to actually scroll the content in the sim / phone. Seems like I've just missed a setting somewhere...

Been stuck for a day with this now and it's really frustrating when I in the Sim/Phone can see that the ScrollView has more content as it "bounches".

Tips / pointers anyone? Thank's :-)

Also posted on Apple Dev Forum: https://devforums.apple.com/message/588899#588899

Attached are two screendumps of Attributes + Size inspector when the current ScrollView is selected in the Objectslist;
Attached Images
File Type: jpg Skärmavbild 2011-12-06 kl. 10.20.27.jpg (8.6 KB, 8 views)
File Type: jpg Skärmavbild 2011-12-06 kl. 10.22.02.jpg (9.5 KB, 4 views)
__________________
-- Happy Coding

Last edited by _Mac; 12-06-2011 at 05:26 AM.
_Mac is offline   Reply With Quote
Old 12-06-2011, 07:51 AM   #2 (permalink)
Reading the Documentation
 
baja_yu's Avatar
 
Join Date: Sep 2010
Location: 45.255019,19.844908
Posts: 5,414
baja_yu has a spectacular aura about
Default

I think you can't set it in IB. You'll have to do it in code.
baja_yu is offline   Reply With Quote
Old 12-06-2011, 09:04 AM   #3 (permalink)
User Interface expert
 
_Mac's Avatar
 
Join Date: May 2009
Location: Sweden
Posts: 141
_Mac is on a distinguished road
Question

@baja_yu.
Are you really sure? Would much prefer setting it in Storyboard directly, than have to write a custom VC class just for this...
__________________
-- Happy Coding
_Mac is offline   Reply With Quote
Old 12-06-2011, 11:21 AM   #4 (permalink)
Registered Member
 
Join Date: Nov 2011
Posts: 30
adamwaite is on a distinguished road
Default

[yourScroller setScrollEnabled:YES];
[yourScroller setContentSize:CGSizeMake(320, x)];

replace x with how long you want the scroll view to be, you can see this in the ruler bit on your storyboard

I think that's what you wanted yeah?
adamwaite is offline   Reply With Quote
Old 12-08-2011, 07:43 AM   #5 (permalink)
User Interface expert
 
_Mac's Avatar
 
Join Date: May 2009
Location: Sweden
Posts: 141
_Mac is on a distinguished road
Smile

@Adam
Yes. Thank's :-)
__________________
-- Happy Coding
_Mac 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: 462
16 members and 446 guests
7twenty7, brandon6031, Dj_kades, Elad, EvilElf, fredidf, HemiMG, iAppDeveloper, LunarMoon, Mijator, Pauluz85, PixelInteractive, QuantumDoja, sacha1996, smithdale87, usernametaken
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,679
Threads: 94,129
Posts: 402,928
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 09:16 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0