Sign Up Screen - Form
Here we will design a Sign Up Screen. Normally this consists of User detail and Password EditText and a Sign Up Button. Note that In the code the resources used in XML code is the local resource of author. User must need to place the resources with same name or change name of it in code. Resources includes drawable images, color and strings.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#415c74"
android:orientation="vertical">
<TextView
android:id="@+id/register_here"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:gravity="center"
android:textColor="#FFFFFF"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Large"
android:text="Register Here"/>
<TextView
android:id="@+id/already_register"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:textColor="#e42020"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"
android:text="Already Registered? Login Here"/>
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<EditText
android:id="@+id/name"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:background="#FFFFFF"
android:hint="Enter Name Here"
android:inputType="text"
android:textColor="#000000"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<EditText
android:id="@+id/cnic"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:background="#FFFFFF"
android:hint="Enter CNIC Here"
android:inputType="number"
android:textColor="#000000"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<EditText
android:id="@+id/designation"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:background="#FFFFFF"
android:hint="Enter Designation Here"
android:textColor="#000000"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<EditText
android:id="@+id/serial"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:background="#FFFFFF"
android:hint="Enter Serial Number Here"
android:textColor="#000000"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<EditText
android:id="@+id/contact"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:inputType="phone"
android:background="#FFFFFF"
android:hint="Enter Name Here"
android:textColor="#000000"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<EditText
android:id="@+id/password"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:background="#FFFFFF"
android:hint="Enter Password Here"
android:textColor="#000000"
android:inputType="textPassword"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<EditText
android:id="@+id/confirm_password"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:layout_margin="10dp"
android:background="#FFFFFF"
android:hint="Confirm Password Here"
android:textColor="#000000"
android:inputType="textPassword"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Small"/>
<Button
android:id="@+id/signup"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="10dp"
android:gravity="center"
android:layout_margin="10dp"
android:background="#4562cc"
android:text="Sign Up"
android:textColor="#fcf7f7"
android:textAppearance="@android:style/TextAppearance.DeviceDefault.Large"/>
</LinearLayout>
</ScrollView>
</LinearLayout>
|
Comments
Post a Comment