What is wrong with this code?
Code:
if (Titlebox.text == nil) {
UIAlertView *alert = [[UIAlertView alloc] initWithTitle: @"Missing Title..." message:@"Please Enter A Name Into The Title Box!"
delegate:self cancelButtonTitle:@"Ok, OK!"
otherButtonTitles:@"OK", nil];
[alert show];
[alert release];
}
else{
NSLog(@"Saving the current file. File Name is > %@ <. ", Titlebox.text);
}
I am trying to have the user save a file, but I want them to title it first. So I have the code look at the textbox to see if it has anything in it.
I have tried this too
Code:
if (Titlebox.text == @"") {
Both do not work.
The NSLog in the else show up with File Name being nothing
This is from my output thing, debug I think.
Code:
Saving the current sound file. File Name is > <.
Thanks in advance, you will be helping a lot.