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

Mockup & CodeGen, iPhone & iPad
($9.99)

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

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 12-16-2008, 09:58 AM   #3 (permalink)
mipegs
New Member
 
Join Date: Oct 2008
Posts: 57
Default

Ok, here are the codes:

ApplicationDelegate class
the property is declared as follows:

Code:
 
AppInvocationData *appInvocationData;
@property (nonatomic, retain) AppInvocationData *appInvocationData;
Code:
- (BOOL)application:(UIApplication *)application handleOpenURL:(NSURL *)url {
	if ([[url scheme] isEqualToString:@"myUrlScheme"]) {
		NSString *urlString = [url scheme];
		AppInvocationData *invData = [[AppInvocationData alloc] initWithParameters:urlString];
		self.appInvocationData = invData;
		[invData release];
		
		return YES;
	}
	return NO;
}


In the view I handle the data as follows in the viewDidLoad method:

Code:
	
IPhoneClientAppDelegate *appDelegate = (IPhoneClientAppDelegate *) [[UIApplication sharedApplication] delegate];
	AppInvocationData *appInvData = appDelegate.appInvocationData;
	if (appInvData) {
		//TODO -site
		self.txtMeetingUserName.text = appInvData.userName;
		self.txtMeetingId.text = appInvData.meetingId;
		self.txtMeetingPass.text = appInvData.meetingPassword;
	}


When I do something like this:

Code:
- (void)applicationDidFinishLaunching:(UIApplication *)application {
	//test
	NSString *testString = @"myUrlScheme://url_here_...";
	NSURL *url = [NSURL URLWithString:testString];
	[self application:application handleOpenURL:url];
             //test
	
	eventOperationQueue = [[NSOperationQueue alloc] init];
	
	[window addSubview:mainNavigationController.view];
	[window setAutoresizesSubviews:YES];
	[window makeKeyAndVisible];
}
everything is beeing processed correctly.
I'm sure that the url link i processed in the application: handleOpenURL method because when i place [application terminateWithSuccess] code there the app quits.
mipegs is offline   Reply With Quote
 

» Advertisements
» Stats
Members: 158,782
Threads: 89,204
Posts: 380,602
Top Poster: BrianSlick (7,129)
Welcome to our newest member, jameswilliards
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 11:41 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.