Do anyone know how to make actions for the buttons in UIAlertview
? if so, please guide me.
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- gactions CLI crashes on Windows when uploading goo
- how do you prevent page scroll in textarea on mobi
相关文章
- Could I create “Call” button in HTML 5 IPhone appl
- Unable to process app at this time due to a genera
- How do you detect key up / key down events from a
- “Storyboard.storyboard” could not be opened
- Attempt to present UIAlertController on View Contr
- Open iOS 11 Files app via URL Scheme or some other
- Can keyboard of type UIKeyboardTypeNamePhonePad be
- Can not export audiofiles via “open in:” from Voic
Please use this code
First Set delegate for UIAlertView then write its delegate method as follows...
Read the below article , will help you to understand the
UIAlertViewDelegate
.iOS SDK: Working with UIAlertView and UIAlertViewDelegate
If you want to get action for UIAlerView button.
You need to use UIAlertViewDelegate and its method for get action.
For Reference,
Try This Code It Will Works for you...
When buttons are clicked in UIAlertView, its delegate method
gets called. Your delegate must implement this method and check which button was pressed.
If you have multiple alert views, then you can differentiate them by their title as follows: