Wednesday, November 27, 2013

ALERT DIALOGS IN ANDROID USING VS2012

 ALERT DIALOGS IN ANDROID Using vs2012

July 8, 2013

 
 
 
 
 
 
1 Votes

In this post we would see how to display alerts, and we would see some customization.

We would see two types of Alerts, such as a simple alert which has a message, a title, and a button. And a complex alert which would have a title, a message, but three buttons.
Let’s add two buttons for that purpose.

Now in the Activity1.cs, we would get the button controls and subscribe to their click events.

Now on SimpleDialogClick event handler, we would do the following to display a simple dialog.

And on ComplexDialogClick event handler, we would do the following to display the other two buttons.
Here the first button could be used for positive feedback, second button for negative feedback and the third button for canceling the operation.

Let’s run the app and here are the two alert dialogs.



Hope this quick post helps you, thanks for reading.

No comments:

Post a Comment