Watchkit AppIcon - The app icon set named “AppIcon

2019-01-16 05:46发布

There is the Images.xcassets file in my WatchKit App. As soon as I put any icon in that asset build failed with the error message: "The app icon set named "AppIcon" did not have any applicable content."

enter image description here

标签: ios watchkit
8条回答
干净又极端
2楼-- · 2019-01-16 06:17

Most likely your watchKit app icons are not of the correct size. You need follow the instructions in above image

查看更多
爷、活的狠高调
3楼-- · 2019-01-16 06:23

This is an easy method to generate your WatchKit icons, which worked well for me:

  • Upload a source image to http://makeappicon.com
  • Go to Images.xcassets in the WatchKit app
  • Right click on the pane which includes AppIcon, select "Import...", and choose the watchkit folder that makeappicon.com generated for you
查看更多
萌系小妹纸
4楼-- · 2019-01-16 06:26

Lets write it down into lazy mode easy version, all other answers were confusing me the hell out. i hope following help others.

Step 1: AppIcon was empty

enter image description here

Step 2: Want to add icon

so from AppIcon > on row1, col1 on 2x > i drag and dropped, the following invalid image:

enter image description here

Which had actual size as below:

enter image description here

Step 3: when i did build compile, it failed.

enter image description here enter image description here

Step 4: after searching

i found that for 2x the image size should be 40px by 40px so i modified that image into 40px by 40px from that invalid value.

enter image description here enter image description here

Step 5: Info.plist added entry as below.

enter image description here enter image description here

This time the build/compile worked and in my iPhone 7 i have the new icon.

查看更多
成全新的幸福
5楼-- · 2019-01-16 06:29

In my case, I generated the images with required dimensions from Sketch. I then dragged and dropped the png files into the spots. No complaints from Xcode. My app doesn't use watch kit.

However build failed with the error message, "The app icon set named “AppIcon” did not have any applicable content". There were also warnings about the wrong dimensions of the image files. Not sure how Sketch did that but I went back and reconfigured export from Sketch, verified the exported dimensions, drag the new files back to the app icon spots in Xcode. This time build was successful.

Morality, if you see this error message, double check your image dimensions.

查看更多
疯言疯语
7楼-- · 2019-01-16 06:36

Go to MakeAppIcon website, upload your image of AppIcon . It will automatically generate all resize images , give your mail id and get the zip file . And make sure when you upload in Assets.xcassets you used a OPT very clearly for image which size is 2x or 3x depending on your requirement .

查看更多
登录 后发表回答