orientation at start up

"I am having a strange problem with orientation at app startup. This problem shows up on both the iPad simulator and iPad hardware. Lets say I am running in the iPad 2 (8.3) simulator. If the simulator is orented in portrait before I start the app, the views all look fine and when I simulate rotations, all the views rotate and look just fine.

Now if I orient the simulator in landscape before I start the app, the views are properly oriented but larger in size. Now when I simulate rotations, all the views rotate but the size is still too large and there is no way to recover other than stopping the app, rotate the hardware, and restart the app again.

My main view is a split screen in landscape but not in portrait. If I start the app with the simulator in landscape, the main view comes up split screen like it supposed to but the display view on the right is the one that is too large. The view looks like it goes off the screen to the right and bottom.

By split screen I mean a scrollable list view on the left and a normal view on the right similar to the Apple settings screen where you have items scrolling on the left side and a display on the right.

Before you ask to see my code, does this sound like some basic setting I am missing or doing wrong? Speaking of code, I wouldn't even know what part of my code would be relevant to show.


Thanks for any help you can offer.


Anyone?


Ok how about this. I thought of a work around this problem but don't know how to do that either. If I could force my app to assume the portrait mode at start up, no matter what the hardware orientation, and then enable rotation sometime after, the problem would be hidden. Obviously a band aide but I can't figure this out and apparently no one else can either.

To try to implement this trick, I first set only the two protrait modes in the info Plist for the target. That stopped the app from rotating to either landscape orientation. Then, according to the "Dynamically Controlling whether Rotation Occurs" documentation, I should be able to minipulate orientations with the "supportedInterfaceOrientations" and "shouldAutorotate" functions. But that doesn't seem to work. Atleast I don't know how to do it.

Can one of you super IOS gurus help me out?

I'm getting desperate! :-)

6 years late, but I've just experienced this and it's the Info.plist settings:

Supported interface orientations (iPad)

which included all possible orientations despite setting just Landscape in the Build Settings. It's been this way for as long as I can remember, but I don't know why...

Anyway delete the orientations you don't want and ensure the iOS Simulator has Device > Rotate Device Automatically turned on and you should be golden.

orientation at start up
 
 
Q