Can I change app icon programmatically

后端 未结 8 2110
执笔经年
执笔经年 2020-11-30 11:44

I have two app icons built-in (free and premium), is it possible to replace free icon to premium icon programmatically after in-app purchase is completed successfully?

相关标签:
8条回答
  • 2020-11-30 11:58

    No, the icon is specified in the application bundle, which you must not change. If you change it, your app signature will become invalid (not the same checksum) and thus your app won't run anymore.

    0 讨论(0)
  • 2020-11-30 11:59

    I don't think that's possible without a jailbroken phone. The app icon is contained in the application bundle, which you're not allowed to write to.

    0 讨论(0)
  • 2020-11-30 12:01

    This is not possible. App icons are not dynamic and they can only be updated by submitting a new updates to your app through iTunes Connect. For more info, read the iTunes Connect Developer Guide. https://itunesconnect.apple.com/docs/iTunesConnect_DeveloperGuide.pdf

    0 讨论(0)
  • 2020-11-30 12:11

    No, definitely not. That part of the application bundle is read-only, and also code signed.

    The answer regarding the TapOne app is something completely different. It creates "web clips" to web sites or phone numbers. For example, to create an iPhone icon for your website, you would add something like this to your web page header:

    <link rel="apple-touch-icon" href="/your-custom-icon.png"/>
    

    There is more info available here: https://developer.apple.com/library/ios/documentation/AppleApplications/Reference/SafariWebContent/ConfiguringWebApplications/ConfiguringWebApplications.html

    TapOne and web clips do not programmatically change the icon within an application bundle.

    0 讨论(0)
  • 2020-11-30 12:18

    An update: since iOS 10.3 you can update the app icon by having alternate icons defined in the info.plist.

    See more at Apple Docs

    0 讨论(0)
  • 2020-11-30 12:19

    I'm afraid not; pretty certain the app icon isn't allowed to conditionally change.

    0 讨论(0)
提交回复
热议问题