Using ModalAlert from cookbook - app does not load
- by user127091
I'm using iphone cookbook code to prompt a user for text in a UIAlertView. The cookbook code is available at
http://github.com/erica/iphone-3.0-cookbook-/tree/master/C10-Alerts/03-Soliciting%20Text/
In my AppDelegate, applicationDidFinishLaunching(), I invoke as below
NSString *str = [ModalAlert ask:@"what is your name?" withTextPrompt:@"ATTUID"];
But my app does not finish loading at all. I get a black screen indefinitely. There are no messages in the console.
I tried creating just a UIAlertView with UITextField in the above function and it displays properly. (commenting out her code) Commenting out "CFRunLoopRun()" also loads the app.
I'm probably doing something stupid but can't seem to figure it out.