Hello Friends,In this blog we are understand how to arise popup on platform specific level in xamarin.iOS.
When we use popup at platform specific level then we can customize popup as our requirement however in this post we show a how to arise a simple popup.
for show popup on iOS firstly we how to initiallize the Controller for popup UIAlertController then put Actions on this controller and at the end this controller is show on current ViewController
The Code is as follows:
var Cantroller = UIAlertController.Create("Title Here", "Massege Here", UIAlertControllerStyle.Alert);
Cantroller.AddAction(UIAlertAction.Create("Okey", UIAlertActionStyle.Default, null));
var Window = UIApplication.SharedApplication.KeyWindow;
var vc = Window.RootViewController;
vc.PresentViewController(Cantroller, true, null);
Cantroller.AddAction(UIAlertAction.Create("Okey", UIAlertActionStyle.Default, null));
var Window = UIApplication.SharedApplication.KeyWindow;
var vc = Window.RootViewController;
vc.PresentViewController(Cantroller, true, null);
No comments:
Post a Comment