Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 09-01-2008, 06:42 AM   #1 (permalink)
Mac
New Member
 
Join Date: Sep 2008
Posts: 9
Mac is on a distinguished road
Default Changin App Icon on AppState

HI Folks,

i´m new to iPhone Development and have, hopefully a simple question.

I´d like to change my App Icon from inside my appliction.
For instance: I change a setting in my app, based on that the icon should change.

Is there any chance to implement that?

I´ve seen it on the Calendar App on the Iphone.

Just another question.

I´ve searched the hole API, but i cant find a way to disable/enable the WiFi via my App.

Thank you!!!

Mac
Mac is offline   Reply With Quote
Old 09-01-2008, 09:55 AM   #2 (permalink)
1026 Development
 
Join Date: Jul 2008
Age: 23
Posts: 1,094
Jeremy1026 is on a distinguished road
Send a message via AIM to Jeremy1026
Default

Quote:
Originally Posted by Mac View Post
I´ve searched the hole API, but i cant find a way to disable/enable the WiFi via my App.
You haven't been able to find it because you can't turn on or off system settings, including WiFi, 3G, location services, etc.
Jeremy1026 is offline   Reply With Quote
Old 09-01-2008, 10:21 AM   #3 (permalink)
Mac
New Member
 
Join Date: Sep 2008
Posts: 9
Mac is on a distinguished road
Default

Thanks for that.
Mac is offline   Reply With Quote
Old 09-01-2008, 10:24 AM   #4 (permalink)
Registered Member
 
Join Date: Aug 2008
Posts: 177
skinrock is on a distinguished road
Default

That's a good point about the calendar app. Does anyone know if you could make the Icon.png just an Objective-C class that spits out a png? Kind of like PHP, where you can hide PHP script inside say a jpg and use header() to tell the browser it's an image.
skinrock is offline   Reply With Quote
Old 09-02-2008, 04:52 AM   #5 (permalink)
Mac
New Member
 
Join Date: Sep 2008
Posts: 9
Mac is on a distinguished road
Default

Quote:
Originally Posted by skinrock View Post
That's a good point about the calendar app. Does anyone know if you could make the Icon.png just an Objective-C class that spits out a png? Kind of like PHP, where you can hide PHP script inside say a jpg and use header() to tell the browser it's an image.

i think that will not work. but i dont know it exactly.
probably this task will work. be careful its just an idea that comes this night

what if we can replace the Icon.png via our app on the iphone itself. i think that isnt a hard task to do. some i/o operations and everything is fine.
but if this has to work, we must have access to the filesystem where iphone puts its appdata. at this point, i dont know if this is possible.

i´ll try it and give a feedback.
Mac is offline   Reply With Quote
Old 09-02-2008, 08:23 AM   #6 (permalink)
Tutorial Author
 
Join Date: May 2008
Posts: 315
myersn024 is an unknown quantity at this point
Default

Actually, you do have access to where your icon.png file is stored, but I don't know whether or not you can change it from inside your program. To access your resource path (the place where your binary, NIBs, and other picture files are) you can do the following. In this example I'll show how to access the path to the icon.png.

Code:
NSString *path = [[NSBundle mainBundle] resourcePath];
NSString *iconPath = [path stringByAppendingPathComponent:@"icon.png"];
Like I said, you have access to the resource path, but I don't know if you can change anything that's stored there. Furthermore, even if you could, it would probably require registering your icon with the same service that updates the Calendar icon since most changes to things on SpringBoard require re-springing before they show up.
myersn024 is offline   Reply With Quote
Old 09-02-2008, 10:21 AM   #7 (permalink)
New Member
 
Join Date: Apr 2008
Posts: 802
scottiphone is on a distinguished road
Default

You can't write to the bundle area.
scottiphone is offline   Reply With Quote
Old 09-19-2008, 03:40 PM   #8 (permalink)
Registered Member
 
roberthuttinger's Avatar
 
Join Date: Sep 2008
Posts: 96
roberthuttinger is on a distinguished road
Default

Quote:
I´ve seen it on the Calendar App on the Iphone.
do you mean the number at the top right? that is controlled byt he app...
roberthuttinger is offline   Reply With Quote
Old 09-19-2008, 04:05 PM   #9 (permalink)
Registered Member
 
Join Date: Sep 2008
Posts: 162
Pring is on a distinguished road
Default

Not possible, unfortunately. By changing the icon you'd break the codesign and you'd be unable to launch the app. The bundle must stay as it is, nothing in it can change.

You can add a badge to the icon, but only when your app is active. When Push Notification comes about you'll be able to add a badge without your app being open.
Pring is offline   Reply With Quote
Old 09-19-2008, 07:42 PM   #10 (permalink)
Registered Member
 
Join Date: Aug 2008
Posts: 177
skinrock is on a distinguished road
Default

Quote:
Originally Posted by roberthuttinger View Post
do you mean the number at the top right? that is controlled byt he app...
No, I know about that one. I'm talking about the icon itself...the date changes every day...
skinrock is offline   Reply With Quote
Reply

Bookmarks

Tags
icon, wifi

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 344
10 members and 334 guests
alexP, ClerurcifeDer, Duncan C, givensur, glenn_sayers, guusleijsten, JmayLive, Punkjumper, whitey99, yys
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,649
Threads: 94,114
Posts: 402,883
Top Poster: BrianSlick (7,990)
Welcome to our newest member, Anwerbl
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 09:41 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0