Search code examples
xcodexamarin.iosuistoryboardios-universal-appxamarin

How to add login to IOS MasterDetail Universal Project?


I'm new to IOS development. I'm wanting to add to a new storyboard project that is a universal masterdetail a simple login control that is required before the user can go any further. that is, I always want them logged in. I'm using monotouch, but I don't think this question is monotouch specific.

Thanks


Solution

  • Generally for login screens, I do the following:

    • In ViewDidAppear of your root view controller, check if your user needs to login
    • Use PresentModalViewController to display your login screen modally

    This should work for any type of controller you are using as the root controller.

    There are certainly other approaches, but this one has always worked for me.