Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Changing the location for "Info.plist" in Xcode

Before you say that this is a minor problem and was discussed a million times here and on other forums, I want to say that I went through all of them and tried to implement each of their solutions but with no luck. I either missed some very small detail or there is something wrong with my project in general. Hope you might help.

The problem: After I've changed the location of "Info.plist" my project shows black screen.

Or I get the following errors:

enter image description here

What I've already tried:

  1. In "Target membership" checked or unchecked the box with the project name
  2. In "Targets" - "Build settings" - "Info.plist File" changed location to "Personal Quiz/Supporting files/Info.plist" plus tried all the other possible paths.
  3. In "Targets" - "Build Phases" - "Copy Bundle Resources" - deleted and add "Info.plist
  4. In File "Info" - "File Inspector" - "Location" changed to "Absolute path", "Relative to group", "Relative to project" and mirrored chosen path path to "Build settings"
  5. In simulation - "Device" - "Erase all content and settings"
  6. "Command + Shift + K" to clean the project
  7. Tried to read apple developers book
  8. Tried to implement some code
  9. Tried some other actions that I can't even recall

As a result I either have a black screen or errors above. What am I doing wrong?

like image 857
Rayce Miller Avatar asked Nov 21 '25 15:11

Rayce Miller


1 Answers

It might be the occurrence of multiple info.plist files. So the solution is:

Go to your Bundle settings -> Open Target -> Open Build Phases > Expand Copy Bundle Resources and remove info.plist from there.

enter image description here

Now try to run your project. I hope it fixes your problem.

Note: Also check the path of your info.plist file

Copy the path by selecting info.plist file -> Goto File Inspector -> Location: select Relative to project -> And copy that path

enter image description here

Now go to your Bundle settings -> Open Build Settings -> In Packaging edit Info.plist File -> And paste the path which you copied earlier.

enter image description here

like image 69
Hassan Avatar answered Nov 24 '25 06:11

Hassan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!