¡@

Home 

2014/10/15 ¤U¤È 10:11:47

iphone Programming Glossary: mysecretstring

Can a UIAlertView pass a string and an int through a delegate

http://stackoverflow.com/questions/5439560/can-a-uialertview-pass-a-string-and-an-int-through-a-delegate

the user doesn't press cancel. Here's my code void doStuff complicated time consuming code here to produce NSString mySecretString self complicatedRoutine int myInt self otherComplicatedRoutine UIAlertView alert UIAlertView alloc initWithTitle @ HERE'S.. UIAlertView alert UIAlertView alloc initWithTitle @ HERE'S THE STUFF message myPublicString derived from mySecretString delegate nil cancelButtonTitle @ Cancel otherButtonTitles @ Go On nil alert setTag 3 alert show alert release .. alertView clickedButtonAtIndex NSInteger buttonIndex if buttonIndex 1 if alertView tag 3 NSLog @ d @ myInt mySecretString However this method doesn't know about mySecretString or myInt . I definitely don't want to recalculate them and I don't..