Roberto Vigo
Roberto Vigo

Reputation: 21

iPad open a modalViewController at application launch

here is my problem: I have an iPad application based on a SplitViewController. When I launch the application, since it always starts in portrait mode, only the Detail pane is shown. All right. I want now open a modalViewController at the application launch for login purpose, but I am not able to find out the right way. I grasp on the web the following code:

SampleModalViewController *sampleView = [[[SampleModalViewController alloc] init] autorelease];
[sampleView setModalTransitionStyle:UIModalTransitionStylePartialCurl];
[self presentModalViewController:sampleView animated:YES];

and it runs nicely, but where do I have to place it in order to have the modal controller displayed at startup? I tried to override viewDidLoad in the DetailViewController, but it does not work.

Thanks for your help! Roberto

Upvotes: 1

Views: 1384

Answers (1)

Roberto Vigo
Roberto Vigo

Reputation: 21

They suggested me an answer:

http://forums.macrumors.com/showthread.php?t=1097839

Upvotes: 1

Related Questions