Xamarin Forms - How to Set Login page at Startup and later change to Home Page Or Change Startup Page

Xamarin Forms


How to Set Login page at Startup and later change to Home Page as Current.MainPage in Xamarin Forms





Step  -1

In-App.XaML.cs

Change MainPage Object from MainPage to PageLogin. This will change the Startup page from Main to Page Login

Code :  Application.Current.MainPage = new PageLogin();

Step 2
Page Login :  In Button of Login (Validation == True)

Code : Application.Current.MainPage = new MainPage();

Note: Once you have Validated User successfully change back to MainPage

Comments

Popular posts from this blog

Rebuild Index

Exclude property of Class Object from Serialization

Multiple Connection from Config File