Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -(void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex
- {
- NSString *msg;
- NSString *prog;
- NSString *game;
- NSString *movie;
- NSString *inter;
- NSString *book;
- NSString *sport;
- if(buttonIndex != [actionSheet cancelButtonIndex])
- {
- if (Programming.on == TRUE || Games.on == TRUE || Movies.on == TRUE || Internet.on == TRUE || Sports.on == TRUE || Books.on == TRUE)
- {
- prog =@"Yes";
- game =@"Yes";
- movie =@"Yes";
- inter =@"Yes";
- book =@"Yes";
- sport =@"Yes";
- }
- else
- {
- prog =@"No";
- game =@"No";
- movie =@"No";
- inter =@"No";
- book =@"No";
- sport =@"No";
- }
- msg = [[NSString alloc] initWithFormat:@"User created with the following preferences: \n Username:%@ \n Password:%@ \n Semester:%@ Major:%@ \n The user has the following interests: \n Programming:%@", UsernameText.text, PasswordText.text, Number.text, MajorText.text, prog];
- }
- UIAlertView *alert=[[UIAlertView alloc]
- initWithTitle:@"Success"
- message:msg
- delegate:self
- cancelButtonTitle:@"Cancel"
- otherButtonTitles:nil];
- [alert show];
- [alert release];
- [msg release];
- }
Add Comment
Please, Sign In to add comment