Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

How to Navigate UIViewController to/from Xamarin.Forms MasterDetailPage ItemSelected event ?

$
0
0

I have a requirement to implement in-app purchase in my Xamarin.forms application. After digging google about this I came to know that I have to write native IOS code for in-app purchase. So before I could start anything I am stuck at how to navigate to Xamarin.IOS UIViewController from Xamarin.Forms MasterDetailPage ItemSelected Event. I have written the following code and somehow (through dependency service) I managed to open the UIViewController after this but I am unable to find a way to go back to masterdetailpage navigation for my other pages. Where I am wrong please suggest.:

region INativeControllerLoaderService implementation

    public void LoadNativeController (Enums.eNativeController eController)
    {
        window = new UIWindow (UIScreen.MainScreen.Bounds);
        viewController = new NonConsumableViewController();
        navigationController = new UINavigationController();
        navigationController.PushViewController (viewController, false);
        window.RootViewController = navigationController;
        window.MakeKeyAndVisible ();
    }

    #endregion

Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>