Android app that will take the registration info of a student and allow them to login using Firestore












0












$begingroup$


I am trying to create a registration/login form for my Android app (Minimum API Level 23, Android Studio 3.3.1, Using AndroidX Artefacts) with Cloud Firestore where a unique ID (starting with 0001) will be generated serially for every new registration.



I have created a separate activity for the Registration process and I haven't been able to solve the errors there either.



Below is the code for the layout



<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/registerform"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".RegisterActivity">

<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scrollbarStyle="insideInset"
tools:layout_editor_absoluteX="0dp"
tools:layout_editor_absoluteY="44dp">

<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">

<EditText
android:id="@+id/Fname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="97dp"
android:layout_marginTop="40dp"
android:layout_marginEnd="97dp"
android:ems="10"
android:hint="First Name"
android:inputType="textPersonName"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />

<EditText
android:id="@+id/Mname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Middle Name"
android:inputType="textPersonName"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Fname" />

<EditText
android:id="@+id/Lname"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Last Name"
android:inputType="textPersonName"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Mname" />

<EditText
android:id="@+id/Dept"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Department"
android:inputType="text"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Rolln" />

<EditText
android:id="@+id/Branch"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Branch"
android:inputType="text"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Dept" />

<EditText
android:id="@+id/Semester"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Semester"
android:inputType="number"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Branch" />

<EditText
android:id="@+id/Rolln"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Roll Number"
android:inputType="text"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Lname" />

<EditText
android:id="@+id/Email"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Email"
android:inputType="textEmailAddress"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Semester" />

<EditText
android:id="@+id/Password"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="99dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="99dp"
android:ems="10"
android:hint="Password"
android:inputType="textPassword"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Email" />

<EditText
android:id="@+id/PasswordConfirm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="97dp"
android:layout_marginTop="24dp"
android:layout_marginEnd="97dp"
android:ems="10"
android:hint="Confirm Password"
android:inputType="textPassword"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/Password" />

<Button
android:id="@+id/submitbutton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="159dp"
android:layout_marginTop="22dp"
android:layout_marginEnd="160dp"
android:text="Submit"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/PasswordConfirm" />

</androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>

</androidx.constraintlayout.widget.ConstraintLayout>


Below is code from the Register Activity



package com.university.smartattendance;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.widget.Button;
import android.widget.EditText;

public class RegisterActivity extends AppCompatActivity {

private EditText Fname;
private EditText Mname;
private EditText Lname;
private EditText Dept;
private EditText Branch;
private Number Semester;
private EditText Rolln;
private EditText Email;
private textPassword Password;
private textPassword PasswordConfirm;

private Button Submit;

@Override
protected void onCreate(Bundle savedInstanceState) {

Fname=(EditText) findViewById(R.id.Fname);
Mname=(EditText) findViewById(R.id.Mname);
Lname=(EditText) findViewById(R.id.Lname);
Dept=(EditText) findViewById(R.id.Dept);
Branch=(EditText) findViewById(R.id.Branch);
Semester=(Number) findViewById(R.id.Semester);
Rolln=(EditText) findViewById(R.id.Rolln);
Email=(EditText) findViewById(R.id.Email);
Password=(textPassword) findViewById(R.id.Password);
PasswordConfirm=(textPassword) findViewById(R.id.PasswordConfirm);
Submit=(Button) findViewById(R.id.submitbutton);

super.onCreate(savedInstanceState);
setContentView(R.layout.activity_register);
}
}








share







New contributor




DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.







$endgroup$

















    0












    $begingroup$


    I am trying to create a registration/login form for my Android app (Minimum API Level 23, Android Studio 3.3.1, Using AndroidX Artefacts) with Cloud Firestore where a unique ID (starting with 0001) will be generated serially for every new registration.



    I have created a separate activity for the Registration process and I haven't been able to solve the errors there either.



    Below is the code for the layout



    <?xml version="1.0" encoding="utf-8"?>
    <androidx.constraintlayout.widget.ConstraintLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/registerform"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".RegisterActivity">

    <ScrollView
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:scrollbarStyle="insideInset"
    tools:layout_editor_absoluteX="0dp"
    tools:layout_editor_absoluteY="44dp">

    <androidx.constraintlayout.widget.ConstraintLayout
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:orientation="vertical">

    <EditText
    android:id="@+id/Fname"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="97dp"
    android:layout_marginTop="40dp"
    android:layout_marginEnd="97dp"
    android:ems="10"
    android:hint="First Name"
    android:inputType="textPersonName"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toTopOf="parent" />

    <EditText
    android:id="@+id/Mname"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Middle Name"
    android:inputType="textPersonName"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Fname" />

    <EditText
    android:id="@+id/Lname"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Last Name"
    android:inputType="textPersonName"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Mname" />

    <EditText
    android:id="@+id/Dept"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Department"
    android:inputType="text"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Rolln" />

    <EditText
    android:id="@+id/Branch"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Branch"
    android:inputType="text"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Dept" />

    <EditText
    android:id="@+id/Semester"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Semester"
    android:inputType="number"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Branch" />

    <EditText
    android:id="@+id/Rolln"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Roll Number"
    android:inputType="text"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Lname" />

    <EditText
    android:id="@+id/Email"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Email"
    android:inputType="textEmailAddress"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Semester" />

    <EditText
    android:id="@+id/Password"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="99dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="99dp"
    android:ems="10"
    android:hint="Password"
    android:inputType="textPassword"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Email" />

    <EditText
    android:id="@+id/PasswordConfirm"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="97dp"
    android:layout_marginTop="24dp"
    android:layout_marginEnd="97dp"
    android:ems="10"
    android:hint="Confirm Password"
    android:inputType="textPassword"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/Password" />

    <Button
    android:id="@+id/submitbutton"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginStart="159dp"
    android:layout_marginTop="22dp"
    android:layout_marginEnd="160dp"
    android:text="Submit"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/PasswordConfirm" />

    </androidx.constraintlayout.widget.ConstraintLayout>
    </ScrollView>

    </androidx.constraintlayout.widget.ConstraintLayout>


    Below is code from the Register Activity



    package com.university.smartattendance;

    import androidx.appcompat.app.AppCompatActivity;

    import android.os.Bundle;
    import android.widget.Button;
    import android.widget.EditText;

    public class RegisterActivity extends AppCompatActivity {

    private EditText Fname;
    private EditText Mname;
    private EditText Lname;
    private EditText Dept;
    private EditText Branch;
    private Number Semester;
    private EditText Rolln;
    private EditText Email;
    private textPassword Password;
    private textPassword PasswordConfirm;

    private Button Submit;

    @Override
    protected void onCreate(Bundle savedInstanceState) {

    Fname=(EditText) findViewById(R.id.Fname);
    Mname=(EditText) findViewById(R.id.Mname);
    Lname=(EditText) findViewById(R.id.Lname);
    Dept=(EditText) findViewById(R.id.Dept);
    Branch=(EditText) findViewById(R.id.Branch);
    Semester=(Number) findViewById(R.id.Semester);
    Rolln=(EditText) findViewById(R.id.Rolln);
    Email=(EditText) findViewById(R.id.Email);
    Password=(textPassword) findViewById(R.id.Password);
    PasswordConfirm=(textPassword) findViewById(R.id.PasswordConfirm);
    Submit=(Button) findViewById(R.id.submitbutton);

    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_register);
    }
    }








    share







    New contributor




    DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.







    $endgroup$















      0












      0








      0





      $begingroup$


      I am trying to create a registration/login form for my Android app (Minimum API Level 23, Android Studio 3.3.1, Using AndroidX Artefacts) with Cloud Firestore where a unique ID (starting with 0001) will be generated serially for every new registration.



      I have created a separate activity for the Registration process and I haven't been able to solve the errors there either.



      Below is the code for the layout



      <?xml version="1.0" encoding="utf-8"?>
      <androidx.constraintlayout.widget.ConstraintLayout
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      android:id="@+id/registerform"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context=".RegisterActivity">

      <ScrollView
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:scrollbarStyle="insideInset"
      tools:layout_editor_absoluteX="0dp"
      tools:layout_editor_absoluteY="44dp">

      <androidx.constraintlayout.widget.ConstraintLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:orientation="vertical">

      <EditText
      android:id="@+id/Fname"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="97dp"
      android:layout_marginTop="40dp"
      android:layout_marginEnd="97dp"
      android:ems="10"
      android:hint="First Name"
      android:inputType="textPersonName"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toTopOf="parent" />

      <EditText
      android:id="@+id/Mname"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Middle Name"
      android:inputType="textPersonName"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Fname" />

      <EditText
      android:id="@+id/Lname"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Last Name"
      android:inputType="textPersonName"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Mname" />

      <EditText
      android:id="@+id/Dept"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Department"
      android:inputType="text"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Rolln" />

      <EditText
      android:id="@+id/Branch"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Branch"
      android:inputType="text"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Dept" />

      <EditText
      android:id="@+id/Semester"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Semester"
      android:inputType="number"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Branch" />

      <EditText
      android:id="@+id/Rolln"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Roll Number"
      android:inputType="text"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Lname" />

      <EditText
      android:id="@+id/Email"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Email"
      android:inputType="textEmailAddress"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Semester" />

      <EditText
      android:id="@+id/Password"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Password"
      android:inputType="textPassword"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Email" />

      <EditText
      android:id="@+id/PasswordConfirm"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="97dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="97dp"
      android:ems="10"
      android:hint="Confirm Password"
      android:inputType="textPassword"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Password" />

      <Button
      android:id="@+id/submitbutton"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="159dp"
      android:layout_marginTop="22dp"
      android:layout_marginEnd="160dp"
      android:text="Submit"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/PasswordConfirm" />

      </androidx.constraintlayout.widget.ConstraintLayout>
      </ScrollView>

      </androidx.constraintlayout.widget.ConstraintLayout>


      Below is code from the Register Activity



      package com.university.smartattendance;

      import androidx.appcompat.app.AppCompatActivity;

      import android.os.Bundle;
      import android.widget.Button;
      import android.widget.EditText;

      public class RegisterActivity extends AppCompatActivity {

      private EditText Fname;
      private EditText Mname;
      private EditText Lname;
      private EditText Dept;
      private EditText Branch;
      private Number Semester;
      private EditText Rolln;
      private EditText Email;
      private textPassword Password;
      private textPassword PasswordConfirm;

      private Button Submit;

      @Override
      protected void onCreate(Bundle savedInstanceState) {

      Fname=(EditText) findViewById(R.id.Fname);
      Mname=(EditText) findViewById(R.id.Mname);
      Lname=(EditText) findViewById(R.id.Lname);
      Dept=(EditText) findViewById(R.id.Dept);
      Branch=(EditText) findViewById(R.id.Branch);
      Semester=(Number) findViewById(R.id.Semester);
      Rolln=(EditText) findViewById(R.id.Rolln);
      Email=(EditText) findViewById(R.id.Email);
      Password=(textPassword) findViewById(R.id.Password);
      PasswordConfirm=(textPassword) findViewById(R.id.PasswordConfirm);
      Submit=(Button) findViewById(R.id.submitbutton);

      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_register);
      }
      }








      share







      New contributor




      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.







      $endgroup$




      I am trying to create a registration/login form for my Android app (Minimum API Level 23, Android Studio 3.3.1, Using AndroidX Artefacts) with Cloud Firestore where a unique ID (starting with 0001) will be generated serially for every new registration.



      I have created a separate activity for the Registration process and I haven't been able to solve the errors there either.



      Below is the code for the layout



      <?xml version="1.0" encoding="utf-8"?>
      <androidx.constraintlayout.widget.ConstraintLayout
      xmlns:android="http://schemas.android.com/apk/res/android"
      xmlns:app="http://schemas.android.com/apk/res-auto"
      xmlns:tools="http://schemas.android.com/tools"
      android:id="@+id/registerform"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      tools:context=".RegisterActivity">

      <ScrollView
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:scrollbarStyle="insideInset"
      tools:layout_editor_absoluteX="0dp"
      tools:layout_editor_absoluteY="44dp">

      <androidx.constraintlayout.widget.ConstraintLayout
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:orientation="vertical">

      <EditText
      android:id="@+id/Fname"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="97dp"
      android:layout_marginTop="40dp"
      android:layout_marginEnd="97dp"
      android:ems="10"
      android:hint="First Name"
      android:inputType="textPersonName"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toTopOf="parent" />

      <EditText
      android:id="@+id/Mname"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Middle Name"
      android:inputType="textPersonName"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Fname" />

      <EditText
      android:id="@+id/Lname"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Last Name"
      android:inputType="textPersonName"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Mname" />

      <EditText
      android:id="@+id/Dept"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Department"
      android:inputType="text"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Rolln" />

      <EditText
      android:id="@+id/Branch"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Branch"
      android:inputType="text"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Dept" />

      <EditText
      android:id="@+id/Semester"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Semester"
      android:inputType="number"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Branch" />

      <EditText
      android:id="@+id/Rolln"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Roll Number"
      android:inputType="text"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Lname" />

      <EditText
      android:id="@+id/Email"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Email"
      android:inputType="textEmailAddress"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Semester" />

      <EditText
      android:id="@+id/Password"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="99dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="99dp"
      android:ems="10"
      android:hint="Password"
      android:inputType="textPassword"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Email" />

      <EditText
      android:id="@+id/PasswordConfirm"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="97dp"
      android:layout_marginTop="24dp"
      android:layout_marginEnd="97dp"
      android:ems="10"
      android:hint="Confirm Password"
      android:inputType="textPassword"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/Password" />

      <Button
      android:id="@+id/submitbutton"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
      android:layout_marginStart="159dp"
      android:layout_marginTop="22dp"
      android:layout_marginEnd="160dp"
      android:text="Submit"
      app:layout_constraintEnd_toEndOf="parent"
      app:layout_constraintStart_toStartOf="parent"
      app:layout_constraintTop_toBottomOf="@+id/PasswordConfirm" />

      </androidx.constraintlayout.widget.ConstraintLayout>
      </ScrollView>

      </androidx.constraintlayout.widget.ConstraintLayout>


      Below is code from the Register Activity



      package com.university.smartattendance;

      import androidx.appcompat.app.AppCompatActivity;

      import android.os.Bundle;
      import android.widget.Button;
      import android.widget.EditText;

      public class RegisterActivity extends AppCompatActivity {

      private EditText Fname;
      private EditText Mname;
      private EditText Lname;
      private EditText Dept;
      private EditText Branch;
      private Number Semester;
      private EditText Rolln;
      private EditText Email;
      private textPassword Password;
      private textPassword PasswordConfirm;

      private Button Submit;

      @Override
      protected void onCreate(Bundle savedInstanceState) {

      Fname=(EditText) findViewById(R.id.Fname);
      Mname=(EditText) findViewById(R.id.Mname);
      Lname=(EditText) findViewById(R.id.Lname);
      Dept=(EditText) findViewById(R.id.Dept);
      Branch=(EditText) findViewById(R.id.Branch);
      Semester=(Number) findViewById(R.id.Semester);
      Rolln=(EditText) findViewById(R.id.Rolln);
      Email=(EditText) findViewById(R.id.Email);
      Password=(textPassword) findViewById(R.id.Password);
      PasswordConfirm=(textPassword) findViewById(R.id.PasswordConfirm);
      Submit=(Button) findViewById(R.id.submitbutton);

      super.onCreate(savedInstanceState);
      setContentView(R.layout.activity_register);
      }
      }






      java android firebase





      share







      New contributor




      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.










      share







      New contributor




      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.








      share



      share






      New contributor




      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.









      asked 9 mins ago









      DarkNateDarkNate

      11




      11




      New contributor




      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.





      New contributor





      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






      DarkNate is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.






















          0






          active

          oldest

          votes











          Your Answer





          StackExchange.ifUsing("editor", function () {
          return StackExchange.using("mathjaxEditing", function () {
          StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
          StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["\$", "\$"]]);
          });
          });
          }, "mathjax-editing");

          StackExchange.ifUsing("editor", function () {
          StackExchange.using("externalEditor", function () {
          StackExchange.using("snippets", function () {
          StackExchange.snippets.init();
          });
          });
          }, "code-snippets");

          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "196"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });






          DarkNate is a new contributor. Be nice, and check out our Code of Conduct.










          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fcodereview.stackexchange.com%2fquestions%2f214514%2fandroid-app-that-will-take-the-registration-info-of-a-student-and-allow-them-to%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          DarkNate is a new contributor. Be nice, and check out our Code of Conduct.










          draft saved

          draft discarded


















          DarkNate is a new contributor. Be nice, and check out our Code of Conduct.













          DarkNate is a new contributor. Be nice, and check out our Code of Conduct.












          DarkNate is a new contributor. Be nice, and check out our Code of Conduct.
















          Thanks for contributing an answer to Code Review Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          Use MathJax to format equations. MathJax reference.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fcodereview.stackexchange.com%2fquestions%2f214514%2fandroid-app-that-will-take-the-registration-info-of-a-student-and-allow-them-to%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          404 Error Contact Form 7 ajax form submitting

          How to know if a Active Directory user can login interactively

          Refactoring coordinates for Minecraft Pi buildings written in Python