I would like show my view immediately when I call it. I don’t know how to make the view show.
-(IBAction) showProgress: (id) sender {
progressViewController *progress = [[progressViewController alloc] initWithNibName:@"progressViewController" bundle:NULL];
[self.view addSubview:progress.view];
[self someFunctionWhichTakesAgesToBeDone];
}
It’s called from current UIViewController. And the view appears after the long function. How can I show it before the long funcion? Thanks for answer.
https://developer.apple.com/library/mac/#documentation/Cocoa/Reference/Foundation/Classes/nsobject_Class/Reference/Reference.html
use
or put your Sleep() function (i hope it’s anything else, Sleep() func is really bad, as its been told) into another function
MySleepFuncand callinstead of Sleep(3).