Ios app icon not shown and name missing why? - ios

I am having some problems with icon & name of my app and although I finished my app because of these I cant publish it.Its not a code related problem and because of that I asked it on diffrent forums but none gave me right answer so as a last hope I decided to ask it here.
1)I managed to put 57x57 px png icon for my app and when I put the it on my phone it's oke but in itunes my app is shown without a icon.I thought that putting 114x144 px icon should solve this problem but I cant do it.When I rightclick and select the "select-file" in 57x57 I can put any png there but its not avalible on 114x114 when I rightclick there is no "selectfile" option and other options aswell.Also same problem happens in launch images.
Is it the reason of no icon showing problem in my itunes or my app can work without it?
In some pages I saw people talking about putting all png files in root with a info file and made it automaticly but I couldt find any tutorial about it.
2)My second problem is about the name.My project name is kdd2 but of course its not my app name kdd2 was a simple name I gave it a month ago.When I disturbute my app I change the name and save it to my desktop.In desktop its shown with the name I wrote it but when I put it in Δ±tunes or iPhone its name again changes to kdd2 how can I solve it ?
Please help me solve these problems I just cant find any answer around thanks...

To change the app name:
-Click your project in the navigator in Xcode.
-Go to "Build Settings" tab.
-Change "Product Name" under "Packaging'.
To set the icon:
You must right lick the border then "Select File". Do not right click "No image specified".

Related

Runtime warning: Could not load the image "imageName" referenced from a nib in the bundle with identifier "bundleId" [duplicate]

when I load my application it shows a warning message that
"Could not load the "" image referenced from a nib in the bundle with
identifier "
I searched and confirmed all my images. But it still shows that warning.
Select your image(s) in Project Navigator.
Open the File Inspector.
Make sure you have the target selected.
I had the same issue when I Refactor to Storyboard. Apparently the Asset catalog does not transfer the image reference. To fix, see below:
You would notice that your ImageViews is empty from reference.
1 - Click on the ImageView
2 Go to the Utilities bar where you would see you asset image is unknown
3 - Change it back to you image asset
This should fix your error. Hope this helps!
There might be many reasons of this error. To fix this issue you can just follow below given step:
Go to product menu of the Xcode, select clean.
If still you are getting the error, then remove the images from your project and again add the images to your project.
while adding image into the project, make sure that you have selected the Project name inside the "Add to targets". And also enable the "Copy items if needed".
Please Refer below image for better understanding:
Just select the image in Xcode and in right side, File inspector, under 'Target Membership' make sure your project is selected.
Another thing you can do is delete and re insert your image and make sure 'Copy items if needed' is selected and 'Add to targets' your project is selected.
Click on the image file in your Xcode navigator.
Once selected, go to the right side bar (of XCODE) which is
utilities and under file inspector, scroll to target membership and
select your project target file.
Then build and run the project again.
Xcode9 beta2 release note:
Jpeg assets in asset catalogs are not found on iOS 10 or earlier for apps built with Xcode 9. APIcalls for accessing the image such as UIImage.imageNamed: return nil. (32524123)
Workaround: Use png resources or limit app testing to devices running iOS 11 or later.
Xcode9 beta3 release note:
Jpeg assets in asset catalogs are found on iOS 10 or earlier for apps built with Xcode 9.(32524123)
For those that are getting this error while developing a cocoapod
I was trying to use an image from my pod's bundle, thats inside a .xcassets file, in the storyboard. It would show fine in the storyboard but when i ran the app it would crash saying it cant find the resource.
I changed my podspec to include s.resources as well as s.resource_bundles
s.resource_bundles = {
'SDKRes' => ['SDK/Assets/*']
}
s.resources = ['SDK/Assets/*.{xcassets}']
Then it was able to load the resource properly from the storyboard
You can try opening your storyboard or nib as Source Code and then "Find" the image name in it, see if it exists but already invalid in your project, probably you have deleted or changed its name, and now it doesn't seem valid.
I have just updated to XCode 9 and it started giving me this issue. I created a new Image Set in the Assets section and added the images I wanted to this, then re-added them to my tab bar images with custom names and it worked fine. Hope this helps!
PROBLEM
This happened to me seemingly out of the blue on a tab bar controller with icons for each tab. The storyboard was still showing my image icons and the assets existed with the expected names.
MY FIX
Select the tab bar icons in their respective view controller and reassign the image like you did the first time.
This happened to me as well. I was doing everything right when adding the image but for some reason it was not working. I had to click on the image again once added, and then on the right toolbar under "Target Membership" I noticed my project was not selected even though I was selecting it when adding the image. I selected it here and everything worked fine.
I got the same error message (in XCode 8), even though the app ran fine (in the simulator and on the device).
I found the problem: In my storyboard, using the document outline pane, I clicked through every single UIImage, and looking at the attributes inspector for each UIImage - in the Image View section - found that one UIImage had a blank file name (instead of the .png file name containing the image). Reselecting the .png file name from the dropdown box fixed the error message.
I have fetching same issue in xcode 9.
just tick on target membership
I pulled my hair out over this issue for hours and none of the solutions in this thread worked. The problem, in the end, was that the Xcode project files were stored on a Google Drive file stream. As soon as I moved it to the local drive or iCloud it worked fine.
My case was a bit different. I was using an old IBDesignable element which had some property of setting an image directly from the storyboard. Since that element was old, hidden and unused the images it had were not present in my assets folder.
Now Xcode won't be able to search this image since it is not in the project anymore. But if you search in the finder, inside your project, you'll find the XIB/Storyboard in which it is mentioned. From there you can find it manually by opening that XIB or Storyboard as source code and search. Once found either replace them with a new image or remove the unused element.
Look into storyboard file you'll see a question mark icon on any of the imageView (as shown in screenshot below) or UIButton image.
Just correct it and the warning will be gone.
Hope this helps
My guess is that you have an image in the Project Setting->Build Phases->Copy Bundle Resources which loses its reference and appears in Red text color. Remove this image from there and re-add.
This happens often due to relocate the image file after adding into project where image was added as a reference instead of a copy.
May be this can fix your issue.
Urughhh. I tried to fix this with all the above solutions, but nothing worked. What finally worked was:
Delete image from your project and select Move to Trash
Clean project
Close and restart XCode
Rename your image filename so something other than the previous name
Add new image to your project
I was facing the same problem, I solve it by deleting folder and create again and past all images then add reference again.
Based on what #hstdt posted above, it made me think I should check that my image is a filetype that doesn't have any bugs related to it. (https://stackoverflow.com/a/44558948/6804257)
I was using a .gif. I got rid of that image and instead used a .png. Now it works.
Had the same issue and none of these answers worked for me. Instead I restarted the mac and iPhone I was working with and then everything started to work fine again. πŸ€·β€β™‚οΈ
My case is difference. I have more one assets folder. So I added to the wrong one.
Just remove and add to the right.
In my case,removing and adding the assets folder from the target fixed the issue.
Xib sets a wrong name for folder reference images. For example I have the folder like Menu->icon.png. Xib sets the "icon" name for the image. It should be "Menu/icon". So do no set images in xibs if you use a folder reference images.

Xcode Deployment Info and icons using CMake

I've tried looking for info on how to set these (in red) using CMake but have had no luck so far:
1st red box issue:
First of all, even though the device seems like it's been set to 'Universal' correctly, the value isn't being interpreted correctly by Xcode. When I set it to 'Universal' manually using the dropdown, it gives a tab each for iPhone and iPad. Furthermore, I know it's not being interpreted correctly as the app does not function correctly (in my case, neither the launch image nor the app itself run full screen).
I don't think setting orientation programmatically is an option for me since I need the launch image in the correct orientation as well.
So can't do something like this:
How do I programmatically set device orientation in iOS7?
2nd red box issue:
I use an asset file for all my icons, so at the moment I'm having to build using CMake and then press 'Use Asset Catalog' each time.
I found this but doesn't seem very useful:
http://cmake.3232098.n2.nabble.com/Icon-and-Launch-image-support-for-iOS-apps-td7590970.html
Regarding the "1st box issue", I've found that the approach taken by this demo project works really well.
https://github.com/forexample/testapp/blob/master/CMakeLists.txt
They use a templated Info.plist to inject the bundle identifier, etc, during configure. The nice part is then you can modify the orientations in the plist.in file, and then these get translated cleanly to the Info.plist once you open the project.
Regarding the 2nd red box issue, i found that the attribute I needed to set was XCODE_ATTRIBUTE_ASSETCATALOG_COMPILER_APPICON_NAME
For example:
set_target_properties(${TARGET} PROPERTIES
XCODE_ATTRIBUTE_ASSETCATALOG_COMPILER_APPICON_NAME "AppIcon")
For Launch Images I got it to work by setting it in the plist.in file under UILaunchStoryboardName as described in yano's previous answer.

Could not load the "" image referenced from a nib in the bundle with identifier

when I load my application it shows a warning message that
"Could not load the "" image referenced from a nib in the bundle with
identifier "
I searched and confirmed all my images. But it still shows that warning.
Select your image(s) in Project Navigator.
Open the File Inspector.
Make sure you have the target selected.
I had the same issue when I Refactor to Storyboard. Apparently the Asset catalog does not transfer the image reference. To fix, see below:
You would notice that your ImageViews is empty from reference.
1 - Click on the ImageView
2 Go to the Utilities bar where you would see you asset image is unknown
3 - Change it back to you image asset
This should fix your error. Hope this helps!
There might be many reasons of this error. To fix this issue you can just follow below given step:
Go to product menu of the Xcode, select clean.
If still you are getting the error, then remove the images from your project and again add the images to your project.
while adding image into the project, make sure that you have selected the Project name inside the "Add to targets". And also enable the "Copy items if needed".
Please Refer below image for better understanding:
Just select the image in Xcode and in right side, File inspector, under 'Target Membership' make sure your project is selected.
Another thing you can do is delete and re insert your image and make sure 'Copy items if needed' is selected and 'Add to targets' your project is selected.
Click on the image file in your Xcode navigator.
Once selected, go to the right side bar (of XCODE) which is
utilities and under file inspector, scroll to target membership and
select your project target file.
Then build and run the project again.
Xcode9 beta2 release note:
Jpeg assets in asset catalogs are not found on iOS 10 or earlier for apps built with Xcode 9. APIcalls for accessing the image such as UIImage.imageNamed: return nil. (32524123)
Workaround: Use png resources or limit app testing to devices running iOS 11 or later.
Xcode9 beta3 release note:
Jpeg assets in asset catalogs are found on iOS 10 or earlier for apps built with Xcode 9.(32524123)
For those that are getting this error while developing a cocoapod
I was trying to use an image from my pod's bundle, thats inside a .xcassets file, in the storyboard. It would show fine in the storyboard but when i ran the app it would crash saying it cant find the resource.
I changed my podspec to include s.resources as well as s.resource_bundles
s.resource_bundles = {
'SDKRes' => ['SDK/Assets/*']
}
s.resources = ['SDK/Assets/*.{xcassets}']
Then it was able to load the resource properly from the storyboard
You can try opening your storyboard or nib as Source Code and then "Find" the image name in it, see if it exists but already invalid in your project, probably you have deleted or changed its name, and now it doesn't seem valid.
I have just updated to XCode 9 and it started giving me this issue. I created a new Image Set in the Assets section and added the images I wanted to this, then re-added them to my tab bar images with custom names and it worked fine. Hope this helps!
PROBLEM
This happened to me seemingly out of the blue on a tab bar controller with icons for each tab. The storyboard was still showing my image icons and the assets existed with the expected names.
MY FIX
Select the tab bar icons in their respective view controller and reassign the image like you did the first time.
This happened to me as well. I was doing everything right when adding the image but for some reason it was not working. I had to click on the image again once added, and then on the right toolbar under "Target Membership" I noticed my project was not selected even though I was selecting it when adding the image. I selected it here and everything worked fine.
I got the same error message (in XCode 8), even though the app ran fine (in the simulator and on the device).
I found the problem: In my storyboard, using the document outline pane, I clicked through every single UIImage, and looking at the attributes inspector for each UIImage - in the Image View section - found that one UIImage had a blank file name (instead of the .png file name containing the image). Reselecting the .png file name from the dropdown box fixed the error message.
I have fetching same issue in xcode 9.
just tick on target membership
I pulled my hair out over this issue for hours and none of the solutions in this thread worked. The problem, in the end, was that the Xcode project files were stored on a Google Drive file stream. As soon as I moved it to the local drive or iCloud it worked fine.
My case was a bit different. I was using an old IBDesignable element which had some property of setting an image directly from the storyboard. Since that element was old, hidden and unused the images it had were not present in my assets folder.
Now Xcode won't be able to search this image since it is not in the project anymore. But if you search in the finder, inside your project, you'll find the XIB/Storyboard in which it is mentioned. From there you can find it manually by opening that XIB or Storyboard as source code and search. Once found either replace them with a new image or remove the unused element.
Look into storyboard file you'll see a question mark icon on any of the imageView (as shown in screenshot below) or UIButton image.
Just correct it and the warning will be gone.
Hope this helps
My guess is that you have an image in the Project Setting->Build Phases->Copy Bundle Resources which loses its reference and appears in Red text color. Remove this image from there and re-add.
This happens often due to relocate the image file after adding into project where image was added as a reference instead of a copy.
May be this can fix your issue.
Urughhh. I tried to fix this with all the above solutions, but nothing worked. What finally worked was:
Delete image from your project and select Move to Trash
Clean project
Close and restart XCode
Rename your image filename so something other than the previous name
Add new image to your project
I was facing the same problem, I solve it by deleting folder and create again and past all images then add reference again.
Based on what #hstdt posted above, it made me think I should check that my image is a filetype that doesn't have any bugs related to it. (https://stackoverflow.com/a/44558948/6804257)
I was using a .gif. I got rid of that image and instead used a .png. Now it works.
Had the same issue and none of these answers worked for me. Instead I restarted the mac and iPhone I was working with and then everything started to work fine again. πŸ€·β€β™‚οΈ
My case is difference. I have more one assets folder. So I added to the wrong one.
Just remove and add to the right.
In my case,removing and adding the assets folder from the target fixed the issue.
Xib sets a wrong name for folder reference images. For example I have the folder like Menu->icon.png. Xib sets the "icon" name for the image. It should be "Menu/icon". So do no set images in xibs if you use a folder reference images.

iPad Splash Screen setting warning in App Target

These are the splash screen of my iPad application.
Default-Portrait.png (768 × 1024)
Default-Portrait#2x.png (1536 × 2048)
Default-Landscape.png (1024 × 768)
Default-Landscape#2x.png (1024 × 768)
The problem:
I upload all these screen in my application. Then set
Default-Landscape#2x, Default-Landscape & Default-Portrait in App Target as iPad Splash screen.
Now when I try to set Default-Portrait#2x, I find "No image Specified" message in "Portrait Non-Retina" section.
Like this:
And then when try to set Default-Portrait again, I find "No image with correct dimensions found" message in "Portrait Retina" section.
Like this:
And this thing happen no matter how many times I re change them one after one. What is the reason of it? If any one have any clue please share that with me. I check my "image name" and "size", no problem in there. I set these splash in a Cross platform "Cordova" project.
Thanks in advanced. Have a nice day.
Addition:
I also try it with these names, but no luck.
Default-Portrait~iPad.png (768 × 1024)
Default-Portrait~iPad#2x.png (1536 × 2048)
Default-Landscape~iPad.png (1024 × 768)
Default-Landscape~iPad#2x.png (1024 × 768)
List item
I don't know why it didn't take the default name in this case. But I set it with the following name and solve it. If anyone get into the similar problem try with these name:
Default~ipad.png
Default~ipad#2x.png
Default-Landscape~ipad.png
Default-Landscape~ipad#2x.png

Could not load the image referenced from a nib in the bundle with identifier

I had got an iPad application.The ViewContrtoller.xib has got an UIImageView in it. The UIImage of the UIImageView is set through Interface Builder. When I run the application in simulator everything is fine. But when I am trying to run it in iPad the UIImage is not loaded. The message that I am getting is:
HexaPuzzle1.0[3259:207] Could not load the "start.png" image referenced from a nib in the bundle with identifier "com.yourcompany.HexaPuzzle1-0"
2010-12-17 10:57:27.221 HexaPuzzle1.0[3259:207] HexaPuzzle loaded
Any help would be appreciated and will be a great help for me.
The issue has been rectified.
Problem was with the image format. When the image has been edited and saved as PNG-24 everything goes fine.
The application now runs smoothly in simulator and device.
Thanks for all friends who suggested a solution and tried to helped me.
Regards,
Rupesh R Menon
I know it's very late, but this is a solution that also works in Xcode 5, and therefore likely to be useful to people who have this problem in the future.
I have seen a lot of questions like this on the web but none of them seems to have one clear answer. This is, as far as I know, the solution for this problem:
Go to the image in Xcode (no need to re-add or re-generate the
image)
click "show the file inspector"
Make sure the checkbox in the category "Target Membership" is checked. the test check box does not have to be checked to make your app load the image.
The target membership tab looks like this:
if this is already the case, you are working with a broken or damaged file. to rule this out, check if another app (like photoshop) can open your image.
This should do it, hope it helps!
When dragging your start.png file into your project, did you check this option?
I was getting this error in the simulator after upgrading to Xcode 7 / iOS 9 and opening an existing project. The image was present and named correctly, within an XCAssets package.
Turns out the problem was with a parameter within the XCAssets package.
Changing Render As from Default to Original Image solved the problem:
I've had the same problem before. The png file format is not right. Try re-generate the png image file and the problem will be solved.
None of the above worked for me, and the message I got was "could not load the "(null)" image referenced... which means I could not look for the image. Very frustrating. In the end it became a trial and error exercise of going through every xib and storyboard looking for potential conflicts. I finally found it - I had specified a "Selected Image" for a tab bar item which was not needed. As soon as I got rid of that the problem went away.
None of these things work for me. I created a new folder in the projects where I placed the pictures. That worked for me.
This problem was fixed when I changed "add folder reference..." to "add group..." when I import the images to my project. I'd prefer to have folders with live updating, but at least it works now.
Had an image on a XIB (which is replaced by the correct one in code). After finishing this XIB, I renamed the images. So XIB was now referencing a non-existent image.
There is also another potential cause of this problem: If you upgraded to XCode 5 and use both the image asset catalog and "normal" images copied to your project (like you did prior XCode 5). If you then have images with identical names (e.g. "dog.png" and a image set called "dog") it might work in your storyboard and in the simulator, but you'll get this message when run on a real device (where the image will not be shown).
Try moving the images directly to the Resources directory (not in a sub folder)
Make sure the resource isn't too big to be handle.
If you get the error message with the name of the picture, you can search it inside your project and xCode will display immediately the UIImageView with the wrong picture inside UIStoryboard:
Make sure it is included in your Target Membership
Select your "Images.xcassets" file in the file Inspector
Open File Inspector (cmd + opt + 1)
Select your target membership (Usually 1st line)
I had the same problem, but the cause was very different. I was using image sets in the Asset Catalog that varied based on the device idiom: iPad or iPhone.
The framework target they were being added to had been accidentally marked as as having a deployment device type of iPhone, so the images weren't showing up on iPads - they weren't even being copied into the .car file in the framework.
Setting the deployment device type to Universal, as it should have been, solved the problem.
For some reason I was getting error until I put the image in the Assets.xcassets

Resources