iphone - How to create a method to return UIAlertViews? -
I have a question about showing a warning on the screen. The thing is that: I have an app with 20 to 30 different screens (nib) and in every nibb I do some checks whether the user has inserted the text in text edit or not. And some warning messages are similar to the others. As in 3 instructions, the user has a text field to enter his age, and a warning that shows that he leaves it blank What I want to do to make a method to show these alerts, so I There is no need for a single alert on different nibs. Rather than calling a watchful scene in every nibb, I call the method and what kind of caution I call to pop up.
What would be the best way to implement this method?
TIA
You can always assign a new UIAlertView like always, Remember to pass.
This is my method:
- (UIAlertView *) getUIAlertViewWithDelegate: (ID) Representative Title: Cancel Title (NSString *) Title: (NSString *) Cancel { Return [[[UIAlertView alloc] initWithTitle: Title Representative: Representative Cancel Button: Other Cancel Button: Blue] Autorelege]; }
Comments
Post a Comment