john doe
john doe

Reputation: 9660

Black bars on all sides when running iPhone app on iPad

I have an iPhone app and I am trying to run it on iPad. But when I run I see black bars on all the sides as shown below:

enter image description here

I am using a LaunchScreen.storyboard file. The LaunchScreen.storyboard is set as launch screen (checkmark is checked). In the target settings I have the following settings:

enter image description here

Any ideas?

Screenshot:

enter image description here

Upvotes: 0

Views: 1196

Answers (3)

leanne
leanne

Reputation: 8729

The Apple tester did not likely get it wrong. Check the following:

  • Go to your app's target. In the General tab, look at the Deployment section. What is listed for Devices? If it says Universal, change it to iPhone.

  • Go to your info.plist. Remove any keys pertaining to the iPad. (Supported interface orientations (iPad) may be there, for example.)

Now, your app should run correctly on an iPad, even though it was made for iPhone only.

Upvotes: 0

hasan
hasan

Reputation: 24205

Edit: That apple tester got it wrong. your app is good !!!

I created a new project that only support an iphone and ran it on the ipad simulator. I calculated the ratio of the screen inside it is equal to 0.69. the same as the ratio of the screen inside the screen shot sent to you by apple.

Apple tester got it wrong. looks like that is the new behaviour on the iOS 10 and that apple test does not know it. reply to them with this they should accept your app without resubmitting new binary.

Original Answer:

Deleting DerivedData, Clean and remove app from simultator should solve the problem. Or maybe you didn't support iPad:

enter image description here

Upvotes: 1

Krish Solanki
Krish Solanki

Reputation: 269

Its because of app is only for iphone, thats why if you are run in iPad it shows actually iphone's view, Enable for ipad and then check.

Upvotes: 0

Related Questions