1. Are you ready for the Galaxy S20? Here is everything we know so far!

Multi Page Registration form using fragments

Discussion in 'Android Development' started by curtis1997, Feb 14, 2020 at 10:46 AM.

  1. curtis1997

    curtis1997 Lurker
    Thread Starter

    Hi im making a password manager in android studio and storing all the data using firebase. The issue im stuck on is creating the registration form. If i simply had one activity with all information on one page i would be able to set this up. However ive got too much infomation to register and it looks messy. So ive created a single activity and have three fragments. After each page the user will click continue until the final page where the user will sign up and all of the data from each fragment is sent to the database as one.



    fragment 1 is responsible for user info e.g. name, email, phone number. fragment 2 is responsible for master password and fragment 3 is responsible for shared secret.



    having not used fragments im abit lost with the whole process i know you can use interfaces or viewmodels to send data back to the activiy. But what would be the best approach be? ive initialy set up interfaces on each fragment but im unsure how to call these in the activity and then create a method which takes the information from each interface put it into one then send it the database.

    Thanks for any help / ideas.
     

    Advertisement

Loading...

Share This Page

Loading...