I have small problem, it looks like thread can sort it, but I'm not good in threads, I read many tutorials, but still didn't get idea how to sort it. Scenario is: I am saving file to Amazon s3, and it's working perfect, but i decide before uploading the file to amazon, give for user to enter file name, and when i call UIAlertView class, program keep running, and saving file as @"test.txt". Here is a part of the code:
fileNmae = @"test.txt";
fileName = [self getFileName];
NSLog(@"File name is %@", fileName);
/// -----------------------------------
/// Uploading file to Amazon cloud !!!!
/// -----------------------------------
...
and here alert method:
-(NSString*) getFileName {
// some alert method
return @"someFile.name";
}
Thanks