Xamarin.Forms Alert Example with only one button and action


Example

var alertResult = await DisplayAlert("Alert Title", Alert Message, null, "OK");
if(!alertResult)
{
   //do your stuff.
}

Here we will get Ok click action.