Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > iPhone/iPad Programming

Thread Tools Search this Thread Display Modes
Old Apr 9, 2009, 06:24 AM   #1
macrumors regular
Join Date: Aug 2008
Problem with UIImagePickerController

I have created a very simple project that has two viewcontrollers
WelcomeViewController and AddInfoViewController
In the applicationDidFinsihLaunch method

WelcomeScreenViewController* welcome = [ [WelcomeScreenViewController alloc] initWithNibName:@"WelcomeScreen" bundle:nil];
		[window addSubview: welcome.view];
There is a button on Welcome screen on whose click, I show another view controller
as shown:
AddInfoViewController* addinfo = [ [AddInfoViewController alloc] initWithNibName: @"AddInfo" bundle:nil ];
	CGRect f = self.view.frame;
	f.origin.y = 0;
	addinfo.view.frame = f;
	//[navController pushViewController:addchild animated:YES];
	[self.view insertSubview:addinfo.view aboveSubview:self.view];
Then the addinfo has a button to show the UIImagePickerController for selecting an image from photo album

I am also able to get the event when the user select "Choose" for an image
- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingImage:(UIImage *)image editingInfo:(NSDictionary *)editingInfo
	selectPhoto.view.hidden = YES;
	[selectPhoto dismissModalViewControllerAnimated:YES];		
My problem is that when the UIImagePickerController goes away from screen it also takes away the addinfo viewcontroller and I am only seeing the welcomeviewcontroller
What is wrong with my approach?
Any idea??
arnieterm is offline   0 Reply With Quote

MacRumors Forums > Apple Systems and Services > Programming > iPhone/iPad Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

Forum Jump

Similar Threads
thread Thread Starter Forum Replies Last Post
Problem with UIImagePickerController anuhoho iPhone/iPad Programming 1 Jun 20, 2011 07:02 AM
Need help with UIImagePickerController lynkynpark86 iPhone/iPad Programming 3 May 22, 2011 01:48 PM
Problem with getline function. gmcguinn Mac Programming 4 Feb 3, 2011 12:59 PM
Problem with BetterTouchTool TrulyYuki Mac Applications and Mac App Store 2 Dec 14, 2010 06:26 PM
Problems with UIImagePickerController and UIPopoverController on iPad RenoRosco iPhone/iPad Programming 1 May 26, 2010 12:32 PM

All times are GMT -5. The time now is 09:07 AM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013,, LLC