Cass_vbulletin3_import20464
New Member
I need to implement my android layout as the image below:
A - Should hold the components in the following manner
B - Should take up 75% of the screen space and should have a vertical scroll barMy question is, how would my Android XML look like? Guys thanks in advance.My XML is as follows:\[code\] <?xml version="1.0" encoding="utf-8"?><ScrollView xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android1="http://schemas.android.com/apk/res/android" android:id="@+id/tvDate" android:layout_width="fill_parent" android:layout_height="fill_parent" android:fillViewport="true" > <RelativeLayout android1:layout_width="match_parent" android1:layout_height="match_parent" > <NumberPicker android1:id="@+id/numberPicker2" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignTop="@+id/numberPicker1" android1:layout_toRightOf="@+id/numberPicker1" /> <NumberPicker android1:id="@+id/numberPicker3" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignTop="@+id/numberPicker2" android1:layout_toRightOf="@+id/numberPicker2" /> <NumberPicker android1:id="@+id/numberPicker4" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignBottom="@+id/numberPicker3" android1:layout_toRightOf="@+id/numberPicker3" /> <NumberPicker android1:id="@+id/numberPicker5" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignTop="@+id/numberPicker4" android1:layout_toRightOf="@+id/numberPicker4" /> <NumberPicker android1:id="@+id/numberPicker6" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignBottom="@+id/numberPicker5" android1:layout_toRightOf="@+id/numberPicker5" /> <NumberPicker android1:id="@+id/numberPicker7" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignBottom="@+id/numberPicker6" android1:layout_toRightOf="@+id/numberPicker6" /> <NumberPicker android1:id="@+id/numberPicker8" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignTop="@+id/numberPicker7" android1:layout_toRightOf="@+id/numberPicker7" /> <TextView android1:id="@+id/textView1" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignLeft="@+id/numberPicker1" android1:layout_alignParentTop="true" android1:layout_marginTop="22dp" android1:text="Start Mileage" android1:textAppearance="?android:attr/textAppearanceMedium" /> <ImageView android1:id="@+id/imageView1" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignParentTop="true" android1:layout_marginRight="25dp" android1:layout_toLeftOf="@+id/textView1" android1:src="http://stackoverflow.com/questions/14579328/@drawable/line" /> <Button android1:id="@+id/button1" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignParentLeft="true" android1:layout_alignTop="@+id/textView1" android1:layout_toLeftOf="@+id/imageView1" android1:text="Request Bundle" /> <EditText android1:id="@+id/editText2" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignBaseline="@+id/textView3" android1:layout_alignBottom="@+id/textView3" android1:layout_toLeftOf="@+id/imageView1" android1:layout_toRightOf="@+id/textView5" android1:ems="10" /> <TextView android1:id="@+id/textView4" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignLeft="@+id/textView3" android1:layout_below="@+id/editText2" android1:layout_marginTop="29dp" android1:text="Driver Name" android1:textAppearance="?android:attr/textAppearanceSmall" /> <EditText android1:id="@+id/editText3" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignBaseline="@+id/textView4" android1:layout_alignBottom="@+id/textView4" android1:layout_alignRight="@+id/editText2" android1:layout_toRightOf="@+id/textView5" android1:ems="10" /> <TextView android1:id="@+id/textView5" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignLeft="@+id/textView4" android1:layout_below="@+id/editText3" android1:layout_marginTop="31dp" android1:text="Number of passengers" android1:textAppearance="?android:attr/textAppearanceSmall" /> <EditText android1:id="@+id/editText4" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignBaseline="@+id/textView5" android1:layout_alignBottom="@+id/textView5" android1:layout_toLeftOf="@+id/imageView1" android1:layout_toRightOf="@+id/textView5" android1:ems="10" /> <TextView android1:id="@+id/textView3" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignParentLeft="true" android1:layout_below="@+id/button1" android1:layout_marginLeft="26dp" android1:layout_marginTop="27dp" android1:text="Vehicle Number" android1:textAppearance="?android:attr/textAppearanceSmall" /> <TextView android1:id="@+id/textView2" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignLeft="@+id/textView5" android1:layout_centerVertical="true" android1:text="Date" android1:textAppearance="?android:attr/textAppearanceSmall" /> <EditText android1:id="@+id/editText1" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_alignRight="@+id/editText4" android1:layout_centerVertical="true" android1:layout_toRightOf="@+id/textView5" android1:ems="10" > <requestFocus /> </EditText> <NumberPicker android1:id="@+id/numberPicker1" android1:layout_width="wrap_content" android1:layout_height="wrap_content" android1:layout_below="@+id/textView1" android1:layout_marginLeft="242dp" android1:layout_toRightOf="@+id/textView5" /> </RelativeLayout></ScrollView>\[/code\]