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 02-10-2012, 01:37 AM   #1 (permalink)
Registered Member
 
Join Date: Feb 2012
Posts: 3
soonw29 is on a distinguished road
Default didReceiveRemoteNotification load ViewController in storboard

Hi all, i need some advice on how to load ViewController.m file in didReceiveRemoteNotification function with Xcode 4.2 story board. Previously i was able to do so using xib files but recently i changed my project to StoryBoard file and is unable to load ViewController.m again after i receive my remote notification.

I tried using this but failed:


Code:
-(void)application: (UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo{
    for (id key in userInfo){
        NSLog(@"key: %@,value: %@", key, [userInfo objectForKey:key]);
    }
    NSLog(@"Parameter is %@",[userInfo objectForKey:@"acme"]);
    
    param = [userInfo objectForKey:@"acme"]; 
    
    [self loadUI];    
    
}

-(void)loadUI{
  
    UIStoryboard *storyboard = [UIStoryboard storyboardWithName:@"MainStoryboard" bundle:nil];
   
    viewController = [storyboard instantiateViewControllerWithIdentifier:@"ViewController"];
}
soonw29 is offline   Reply With Quote
Old 02-12-2012, 08:02 PM   #2 (permalink)
Registered Member
 
Join Date: Feb 2012
Posts: 3
soonw29 is on a distinguished road
Default

Anybody knows?
soonw29 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: 392
12 members and 380 guests
chiataytuday, chits12345, ChrisYates, fiftysixty, fredidf, gmarro, KennyChong, kilobytedump, Leslie80, Meoz, ryantcb, Yosh_K
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,670
Threads: 94,121
Posts: 402,903
Top Poster: BrianSlick (7,990)
Welcome to our newest member, Yosh_K
Powered by vBadvanced CMPS v3.1.0

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