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 05-27-2011, 03:11 AM   #1 (permalink)
Registered Member
 
arun's Avatar
 
Join Date: Jul 2009
Location: Chennai,India
Posts: 75
arun is on a distinguished road
Default Push Notification Alert

Hi

I am working with push notification and i am getting the alert for notification.In the alert i have two buttons cancel and view,when i click to view i am opening with home page but i need to open with another view rather than home view. How can i do it,can any one guide me with sample code.

Thanks in Advance,
arun is offline   Reply With Quote
Old 05-27-2011, 03:23 AM   #2 (permalink)
Registered Member
 
ngaikwad's Avatar
 
Join Date: Feb 2011
Location: Mobile World
Posts: 450
ngaikwad is on a distinguished road
Default

Quote:
Originally Posted by arun View Post
Hi

I am working with push notification and i am getting the alert for notification.In the alert i have two buttons cancel and view,when i click to view i am opening with home page but i need to open with another view rather than home view. How can i do it,can any one guide me with sample code.

Thanks in Advance,

create new view and call that view in app delegate
__________________
Thank & Regard
NI3(Not Impossible 3)
ngaikwad is offline   Reply With Quote
Old 05-27-2011, 04:00 AM   #3 (permalink)
Registered Member
 
arun's Avatar
 
Join Date: Jul 2009
Location: Chennai,India
Posts: 75
arun is on a distinguished road
Default

Quote:
Originally Posted by ngaikwad View Post
create new view and call that view in app delegate
Sorry I can't understand

Actually, now i have homeviewcontroller which i am pointing as root viewcontroller as shown below already in AppDelegate

Code:
homeview *start=[[homeview alloc] initWithNibName:@"homeview" bundle:nil];
nav=[[UINavigationController alloc] initWithRootViewController:start];
[nav.navigationBar setHidden:YES];
[self.window addSubview:nav.view]
;


And now i have to point out anotherviewController as first one when notification arrive while click on to view button.How can i do it?
arun is offline   Reply With Quote
Old 05-27-2011, 06:00 AM   #4 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

Quote:
Originally Posted by ngaikwad View Post
create new view and call that view in app delegate
again another general\useless answer
sorry but i can't stop to highlight it when i see such responses....

@arun you need to check UIApplicationDelegate Protocol
Code:
//The user launched the application in response to the arrival of a remote notification. In this case, the dictionary contains the notification payload dictionary described in the application:didReceiveRemoteNotification: method. (Key: UIApplicationLaunchOptionsRemoteNotificationKey)

//The user launched the application in response to the arrival of a local notification. In this case, the dictionary contains the local notification. (Key: UIApplicationLaunchOptionsLocalNotificationKey) 


- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
and maybe
Code:
//Sent to the delegate when a running application receives a remote notification.
- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo
__________________
dany_dev is offline   Reply With Quote
Old 05-27-2011, 06:16 AM   #5 (permalink)
Registered Member
 
ngaikwad's Avatar
 
Join Date: Feb 2011
Location: Mobile World
Posts: 450
ngaikwad is on a distinguished road
Angry

Quote:
Originally Posted by dany_dev View Post
again another general\useless answer
sorry but i can't stop to highlight it when i see such responses....

@arun you need to check UIApplicationDelegate Protocol
Code:
//The user launched the application in response to the arrival of a remote notification. In this case, the dictionary contains the notification payload dictionary described in the application:didReceiveRemoteNotification: method. (Key: UIApplicationLaunchOptionsRemoteNotificationKey)

//The user launched the application in response to the arrival of a local notification. In this case, the dictionary contains the local notification. (Key: UIApplicationLaunchOptionsLocalNotificationKey) 


- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
and maybe
Code:
//Sent to the delegate when a running application receives a remote notification.
- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo
Both answer are same

If you think you are best then ok
__________________
Thank & Regard
NI3(Not Impossible 3)
ngaikwad is offline   Reply With Quote
Old 05-27-2011, 06:33 AM   #6 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

Quote:
Originally Posted by ngaikwad View Post
Both answer are same

If you think you are best then ok
no, the anwers are not the same, it's what I like that you understand.

Your answer contain inexact\incomplete terms that are completely useless for a beginner, because if he already know how to use "app delegate" (note that in this context is incorrect calling it in this mode) would not asked here.

I'm not "best than you", I believe just that an answer should be BEST than your

just take your last 10-50 posts and see how many times a user understand your cryptic\useless\general\imprecise answer at the first read.....
__________________

Last edited by dany_dev; 05-27-2011 at 06:35 AM.
dany_dev is offline   Reply With Quote
Old 05-27-2011, 06:37 AM   #7 (permalink)
Registered Member
 
ngaikwad's Avatar
 
Join Date: Feb 2011
Location: Mobile World
Posts: 450
ngaikwad is on a distinguished road
Default

Quote:
Originally Posted by dany_dev View Post
Your answer contain inexact\uncomplete terms that are completely useless for a beginner, because if he already know how use "app delegate" (note that in this context is incorrect calling it in this mode) would not asked here.
This can be acceptable...............
Quote:
just take your last 10 posts and see how many times a user understand your cryptic\useless\general\imprecise answer at the first read.....
about this your are saying lot of things ...........
__________________
Thank & Regard
NI3(Not Impossible 3)
ngaikwad is offline   Reply With Quote
Old 05-27-2011, 07:14 AM   #8 (permalink)
Registered Member
 
arun's Avatar
 
Join Date: Jul 2009
Location: Chennai,India
Posts: 75
arun is on a distinguished road
Default

Quote:
Originally Posted by dany_dev View Post
no, the anwers are not the same, it's what I like that you understand.

Your answer contain inexact\incomplete terms that are completely useless for a beginner, because if he already know how to use "app delegate" (note that in this context is incorrect calling it in this mode) would not asked here.

I'm not "best than you", I believe just that an answer should be BEST than your

just take your last 10-50 posts and see how many times a user understand your cryptic\useless\general\imprecise answer at the first read.....

when i launch the application at first and i receive the notification and click on to view option it is not invoking the
Code:
didReceiveRemoteNotification
arun is offline   Reply With Quote
Old 05-27-2011, 07:57 AM   #9 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

Quote:
Originally Posted by arun View Post
when i launch the application at first and i receive the notification and click on to view option it is not invoking the
Code:
didReceiveRemoteNotification
re-read carefully the documentation.....
__________________
dany_dev is offline   Reply With Quote
Old 05-27-2011, 08:07 AM   #10 (permalink)
Registered Member
 
arun's Avatar
 
Join Date: Jul 2009
Location: Chennai,India
Posts: 75
arun is on a distinguished road
Default

Quote:
Originally Posted by dany_dev View Post
re-read carefully the documentation.....
ok
arun is offline   Reply With Quote
Reply

Bookmarks

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: 338
6 members and 332 guests
doffing81, dre, iOS.Lover, jenniead38, Kirkout, Wikiboo
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,663
Threads: 94,120
Posts: 402,898
Top Poster: BrianSlick (7,990)
Welcome to our newest member, LezB44
Powered by vBadvanced CMPS v3.1.0

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