How to set up login pin system

i want to set up basic login page in xamarin.forms. There is no username/password, just a simple pin so far i have 3 pages to do this Sign-up Pin page Sign-up Confirm Pin Page (re-enter pin to confirm) Sign-in Pin Page Main app page my project flow as follows: 1st time user, will be prompt to "Sign-up Pin Page", than "Sign-up Confirm Pin Page", than "Main app page" user that already have created a PIN, will be prompt to "Sign-in Pin Page", than "Main App Page. issue is that "Sign-up Pin Page", "Sign-up Confirm Pin Page", and "Sign-in Pin Page" all have the same view, other than a label. 95% of the code is same. so if i make a small change like change color, than i will have to do in 3 different pages my question is, is there better way to do this. should I use just one page to handle 3 pages? and do if/else to see which stage of flow user is in?

Feb 4, 2025 - 11:43
 0
How to set up login pin system

i want to set up basic login page in xamarin.forms. There is no username/password, just a simple pin

so far i have 3 pages to do this

  • Sign-up Pin page
  • Sign-up Confirm Pin Page (re-enter pin to confirm)
  • Sign-in Pin Page
  • Main app page

my project flow as follows:

  • 1st time user, will be prompt to "Sign-up Pin Page", than "Sign-up Confirm Pin Page", than "Main app page"

  • user that already have created a PIN, will be prompt to "Sign-in Pin Page", than "Main App Page.

issue is that "Sign-up Pin Page", "Sign-up Confirm Pin Page", and "Sign-in Pin Page" all have the same view, other than a label. 95% of the code is same. so if i make a small change like change color, than i will have to do in 3 different pages

my question is, is there better way to do this. should I use just one page to handle 3 pages? and do if/else to see which stage of flow user is in?