I am trying to make a layout which resembles a Grid Layout, but I am restrained to Android 2.0
Does anyone have any ideas?
<?xml version="1.0" encoding="UTF-8"?>
<GridLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:columnCount="2"
android:rowCount="13" >
<TextView
android:layout_gravity="fill_horizontal"
android:text="SN : " />
<TextView
android:id="@+id/snTextView"
android:layout_gravity="fill_horizontal" />
<TextView
android:layout_gravity="fill_horizontal"
android:text="Ver : " />
<TextView
android:id="@+id/verTextView"
android:layout_gravity="fill_horizontal" />
<TextView
android:layout_gravity="fill_horizontal"
android:text="Type : " />
<TextView
android:id="@+id/typeTextView"
android:layout_gravity="fill_horizontal" />
<TextView
android:layout_gravity="fill_horizontal"
android:text="OD : " />
<TextView
android:id="@+id/odTextView"
android:layout_gravity="fill_horizontal" />
<TextView
android:text="Closing Mode"
android:layout_gravity="fill_horizontal" />
<TextView
android:id="@+id/closingModeTextView"
android:layout_gravity="fill_horizontal" />
<TextView
android:text="CT : "
android:layout_gravity="fill_horizontal" />
</GridLayout>
EDIT:
hmm, I had began coding about half an hour ago in the .xml file, I'll post the code above. To see how the first part of it looked, I went to the Graphical Layout, and the following error came up...
"com.android.layoutlib.bridge.MockView cannot be cast to android.view.ViewGroup Exception details are logged in Window>Show View> Error Log The following classes could not be found: - GridLayout( Fix Build Path, Edit XML )"
I guess it may be that something else is wrong, but in the Graphical Layout pallete GridLayout is not listed, while the rest of them are( Linear(vert/hoz), Relative, Frame, Fragment, Table, etc. )