views:

2644

answers:

2

Is there any way to change the 47x47 PNG, pointed to within info.plist, for the iPhone springboard icon from within code?

I understand I can add a translation and change the springboard icon per language that the iPhone supports via a changed info.plist per language, but I would like to change the springboard icon for my iPhone app based on a user preference within the app.

Any ideas?

I haven't tried this, but can a file be copied over another within an app bundle? Could I ship with info.plist pointing to "base.png" then replace "base.png" with another PNG I package with my app from within code?

Thanks.

--Batgar

+5  A: 

This cannot be done - an iPhone application main bundle is read only, so you cannot change your app icon from within your app.

zPesk
Thanks zPesk. I figured as much. So it appears my only recourse is to ship out an entirely different app with the different icon, or to come up with a general icon that spans the "marketing space" of the application and customize internally.Thanks again.
Batgar
alternatively, when you submit an update to your app, you could alter the app's icon
zPesk
To make a long story short, I work for a company that has many sister companies. They want the app branded for each sister company at the springboard without having to submit a different app per sister company. We have 10 different sister companies, and the only major difference is going to be the springboard icon. That said, I am pretty sure we will find a need to customize a given string or image for a specific company, which means that we will need to ship the app per company anyway. Such is life.
Batgar
would you be submitting to the app store or do an in-house distribution???
zPesk
A: 

What you want to do is create a new target (with the relevant icon) for each "sister" app and that will allow you to compile multiple apps using the same code base. Hope this helps!

jessem