Why does my App Icon not show up?

StephanSchmidtStephanSchmidt DEMember ✭✭
edited August 2015 in Xamarin.iOS

Hello guys,

I just want to know if anyone else ran into this issue.

On Xamarin.IOS i am trying to deploy an App to the app store, but whatever i do, the AppIcon does not get deployed, neither in Debug, nor in Release mode. I tried hardcoding the Icon - Files in the Info.Plist. I also tried the normal way using Image assets, i checked all the sizes again, i even tried building the Info.plist and the image asset folder in Xcode and import it, but whatever i do, the app icon doesn't appear to be present in the app bundle. Build action is set to ImageAsset.

Can anyone help?

Thank you

Answers

  • KMullinsKMullins USMember, Xamarin Team Xamurai

    Hi @StephanSchmidt,

    Try the following:

    1. Remove the app from the iOS device that you are testing on.
    2. Delete the bin and obj files from your Xamarin.iOS project.
    3. Ensure that all of you icon files are in place (either via the info.pst file or an Image asset).
    4. Do a rebuild and re-install.

    Hope this helps,

    Kevin

  • StephanSchmidtStephanSchmidt DEMember ✭✭

    Hi,

    thanks a lot for your answer,
    but we already tried the steps that you listed. We tried it again now but with no luck. The Info.plist as well as the image asset is in place, and the info.plist points towards AppIcons.appiconset. I also checked the csproj File, everything seems to be alright there as well, except that each app icon file is pointed to twice.
    (See the code i posted below) Could this cause any trouble?
    Please if someone can help it would be great, we are really running out of options here and need to deploy soon.

    <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Contents.json" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-60%402x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-60%403x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-72.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-72%402x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-76.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-76%402x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small-40.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small-40%402x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small-40%403x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small-50.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small-50%402x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small%402x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon-Small%403x.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon.png" />
        <ImageAsset Include="..\ahk_app_ios\Resources\images.xcassets\AppIcons.appiconset\Icon%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Contents.json" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-60%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-60%403x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-72.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-72%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-76.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-76%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small-40.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small-40%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small-40%403x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small-50.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small-50%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small%402x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon-Small%403x.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon.png" />
        <ImageAsset Include="Resources\Images.xcassets\AppIcons.appiconset\Icon%402x.png" />
    
  • StephanSchmidtStephanSchmidt DEMember ✭✭

    After a few more hours wasted i decided to create a completely new project and add all the files again. That solved the issue.

  • I had the same issue.
    Solved it by disable readonly mode from images (readonly mode provides TFS) and reopen plist editor.

  • TheCudaTheCuda USMember
    edited February 2016

    Xamarin has major problem with creating packages. I have seen this behavior time and time again with icons, splash screens, sounds and so on. Basically you can do what is mentioned above or you can sit there and keep cleaning, rebuilding, restarting the environment and hope the thing actually starts working. This has been a very frustrating experience that they do not fix. I have had multiple support tickets in over the years to resolve these issues, yet they keep coming up. Basically, if you can't create a project that proves the problem to them, it will never get fixed.

  • IfeanyiIfeanyi USMember ✭✭

    Hello all, I've been plagued by this issue. I had to recreate an app once just to get things to work. After a while now the icon does not show up. I would have to go through that pain again just to get things working. I even went back a few builds to when it was working and still no luck.

    I have attempted to clean my workspace (entire TFS workspace) and reget all and still no luck. I am using VS 2015 and xamarin iOS.

    Can someone please help me resolve this. Nothing has changed in the icons and the iconset.

  • IfeanyiIfeanyi USMember ✭✭
    edited August 2016

    For anyone that hits this issue, just found a hack that works.
    I spent a couple hours digging into the Visual Studio diagnostic logs and comparing against a new application that builds properly.

    I realized some inconsistency in the parameters passed to the actool and went digging into the Mac because I saw a folder that's being managed on my mac that's under Library/Caches/Xamarin. I cleared it as it had folders for all projects i've ever built and assuming that it really is a cache it should be rebuilt if it doesn't exist.
    I rebuilt and my icons got processed properly.

    The folder is:
    /Users//Library/Caches/Xamarin/mtbs/builds/<Clear everything here or for the specific project that's having icon problems>

    This worked for me. I don't know if it will work for all but worth a shot. Seems Xamarin get's it's tentacles tangled after a while developing against the same Mac Build agent and the same VS project.

    NOTE: The "Library" folder on the mac does not show up by default. Under the "" folder right click and select "Show view options", then check the box to "show Library folder."

    Goodluck!

  • BabaJimBabaJim USMember

    Not sure if anyone is still experiencing this issue, but simply replacing the icons in Assets.xcassets worked for me.

  • MahibaRajaseelanMahibaRajaseelan USMember ✭✭
    edited August 2017

    Hi all, had to roll my head for a full day by trying out many suggestions. Finally got to work by removing and recreating "Images" Asset Catalog.
    Steps:
    1. Take backup for "Images.xcassets" folder with all AppIcons.
    2. Right Click and Delete "Images" Asset Catalog from Solution Explorer.
    3. Right Click and Delete "Images.xcassets" under "Resources" from Solution Explorer.
    4. Right Click "Asset Catalogs" and Add Asset Catalog "Images" from Solution Explorer.
    5. Now open this new "Images" Asset Catalog and add required AppIcon images manually.
    6. Reload/Refresh the solution explorer, you can see "Images.xcassets" under Resources folder. Include in the project.
    7. Clean and Rebuild Solution. if required, delete the app in simulator/device and run.
    8. Open Info.plist designer and under "Visual Assets" tab, Choose "AppIcons" source in App Icons.
    App Icon will appear.

  • AlexSAlexS USUniversity ✭✭✭

    +1 to @MahibaRajaseelan answer.
    Renaming AppIcons to AppIcon did the job. Guess, the caching is the reason as other people mentioned above.

  • @AlexS - Yes, Thanks. It should be caching. Re-doing or recreating the folder,images and AppIcons inside Asset Catelogs is working out.

  • HaiNguyen.6340HaiNguyen.6340 USMember ✭✭

    In case it helps someone in need. Clear cache didn't work for me, but remove & re-add images worked for me. My case it was tab icons didn't show up. I backed up the Resources folder, then removed affected images from it, then re-add images back, and everything seems to work as they supposed to for now. Xamarin needs to fix these issues. I had different issues dealing with images & app icons a number of times.

  • BruceFullwoodBruceFullwood USMember ✭✭

    I know I'm way late to this party, but I wanted to fill you in, "you" being anyone interested, in how I resolved the issue.

    I had migrated a PCL project to .NET Standard by creating a new Solution and simply copying the files over, including the Info.plist. I then created and recreated a Media Asset Catalog over and over without resolving the issue; still no icon.

    I finally looked in the Info.plist and discovered that while the name of the Asset Catalog had changed, it was still pointing to the location from the previous Project. Apparently, Asset Catalogs were stored in the Resources folder and with my new Project, they were created directly in the root of the Project directory. I removed the extra "Resources" path in the directory structure referred to in XSAppIconAssets string tag and voila, my icons were back.

    Personally, I'd call this a bug; that directory string should be accurately-formed, regardless of whether you copied it from a previous project.

  • EricSchmeckEricSchmeck DEMember ✭✭

    @BruceFullwood
    Thank you very much, this worked for me!!

  • HAITHEMCHAMKHIHAITHEMCHAMKHI USMember ✭✭

    i have the same problem and non of these solution resolved my problem

  • sumitmishrasumitmishra Member ✭✭

    I have the same problem in xamarin.ios native app. Can someone please help me to resolve this?

  • ervaerva USMember ✭✭

    @BruceFullwood
    Thanks! That saved me :smile:

  • AboghrisAboghris USMember ✭✭

    @maurogarcia0209
    Thank u , it was done :smile:

  • AntonioXeiraAntonioXeira USMember ✭✭

    @maurogarcia0209 said:
    I fixed that problem following this steps:
    1- Check the folder path for my assets (In my case, it was "[Project]/Media.xcassets/AppIcons.appiconset"
    2- Open Info.plist file with notepad or other text editor
    3- Search for "XSAppIconAssets" key
    4- The value for this key was wrong, It was pointing to "[Project]/Resources/Media.xcassets/AppIcons.appiconset"
    After update this value, clean and rebuild the project and should work.

    That was my problem, XSAppIconAssets and also XSLaunchImageAssets where wrong

  • PeterSchotmanPeterSchotman USMember ✭✭

    Same here XSAppIconAssets and XSLaunchImageAssets where wrong in the plist file

  • Jul14nJul14n Member ✭✭

    @maurogarcia0209 solution worked for me too, thanks :smiley:

  • ToalTronixToalTronix USMember ✭✭

    @maurogarcia0209 ! You are the king. It works

    Why does this happens, and takes so much time from our developers?

  • thank you @maurogarcia0209 saved me!

  • EdwardLinaresEdwardLinares USMember ✭✭
    edited June 2018

    Thanks so much @BruceFullwood finally I could see the icons after a day of work, this obviously is a bug!, I changed the images after apply the Bruce advise and the .plist file took the Resources folder again then I had to change again "manually".

  • HumanHuman USMember

    @maurogarcia0209 said:
    I fixed that problem following this steps:
    1- Check the folder path for my assets (In my case, it was "[Project]/Media.xcassets/AppIcons.appiconset"
    2- Open Info.plist file with notepad or other text editor
    3- Search for "XSAppIconAssets" key
    4- The value for this key was wrong, It was pointing to "[Project]/Resources/Media.xcassets/AppIcons.appiconset"
    After update this value, clean and rebuild the project and should work.

    Thanks, That worked for me.

  • JoeJohnstonJoeJohnston USMember ✭✭

    I know this is basic but make sure the **AppIcon **setting has not been changed. I have had the android team overwrite my plist with a non setting more than once in git.

  • AmruthaVarsha.TamanamAmruthaVarsha.Tamanam USMember ✭✭

    @maurogarcia0209

    I have tried the same steps you mentioned.

    In the info.plist (Source)
    XSAppIconAssets
    Assets.xcassets/AppIcon.appiconset
    and in the info.plist (Application)

Sign In or Register to comment.