[text] activitymain1

Viewer

copydownloadembedprintName: activitymain1
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:tools="http://schemas.android.com/tools"
  4. android:layout_width="match_parent"
  5. android:layout_height="match_parent"
  6. tools:context=".MainActivity">
  7. <LinearLayout
  8. android:layout_width="match_parent"
  9. android:layout_height="100dp">
  10. <TextView
  11. android:id="@+id/textView"
  12. android:layout_width="match_parent"
  13. android:layout_height="wrap_content"
  14. android:layout_margin="30dp"
  15. android:text="Details Form"
  16. android:textSize="25sp"
  17. android:gravity="center"/>
  18. </LinearLayout>
  19. <GridLayout
  20. android:id="@+id/gridLayout"
  21. android:layout_width="match_parent"
  22. android:layout_height="match_parent"
  23. android:layout_marginTop="100dp"
  24. android:layout_marginBottom="200dp"
  25. android:columnCount="2"
  26. android:rowCount="3">
  27. <TextView
  28. android:id="@+id/textView1"
  29. android:layout_width="wrap_content"
  30. android:layout_height="wrap_content"
  31. android:layout_margin="10dp"
  32. android:layout_row="0"
  33. android:layout_column="0"
  34. android:text="Name"
  35. android:textSize="20sp"
  36. android:gravity="center"/>
  37. <EditText
  38. android:id="@+id/editText"
  39. android:layout_width="wrap_content"
  40. android:layout_height="wrap_content"
  41. android:layout_margin="10dp"
  42. android:layout_row="0"
  43. android:layout_column="1"
  44. android:ems="10"/>
  45. <TextView
  46. android:id="@+id/textView2"
  47. android:layout_width="wrap_content"
  48. android:layout_height="wrap_content"
  49. android:layout_margin="10dp"
  50. android:layout_row="1"
  51. android:layout_column="0"
  52. android:text="Reg.No"
  53. android:textSize="20sp"
  54. android:gravity="center"/>
  55. <EditText
  56. android:id="@+id/editText2"
  57. android:layout_width="wrap_content"
  58. android:layout_height="wrap_content"
  59. android:layout_margin="10dp"
  60. android:layout_row="1"
  61. android:layout_column="1"
  62. android:inputType="number"
  63. android:ems="10"/>
  64. <TextView
  65. android:id="@+id/textView3"
  66. android:layout_width="wrap_content"
  67. android:layout_height="wrap_content"
  68. android:layout_margin="10dp"
  69. android:layout_row="2"
  70. android:layout_column="0"
  71. android:text="Dept"
  72. android:textSize="20sp"
  73. android:gravity="center"/>
  74. <Spinner
  75. android:id="@+id/spinner"
  76. android:layout_width="wrap_content"
  77. android:layout_height="wrap_content"
  78. android:layout_margin="10dp"
  79. android:layout_row="2"
  80. android:layout_column="1"
  81. android:spinnerMode="dropdown"/>
  82. </GridLayout>
  83. <Button
  84. android:id="@+id/button"
  85. android:layout_width="wrap_content"
  86. android:layout_height="wrap_content"
  87. android:layout_alignParentBottom="true"
  88. android:layout_centerInParent="true"
  89. android:layout_marginBottom="150dp"
  90. android:text="Submit"/>
  91. </RelativeLayout>

Editor

You can edit this paste and save as new:


File Description
  • activitymain1
  • Paste Code
  • 05 May-2021
  • 2.55 Kb
You can Share it: