I have a TableLayout defined in my xml with three columns and four rows plus a heading row. Each column contains a TextView.
<TableLayout
android:id="@+id/inventory"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:stretchColumns="*"
<TableRow>
<TextView
android:text="Item"/>
<TextView
android:text="Quantity"/>
<TextView
android:text="Units"/>
</TableRow>
<TableRow>
<TextView
android:id="@+id/inventorycell10"
<TextView
android:id="@+id/inventorycell11"
<TextView
android:id="@+id/inventorycell12"
</TableRow>
<TableRow>
<TextView
android:id="@+id/inventorycell20"
<TextView
android:id="@+id/inventorycell21"
<TextView
android:id="@+id/inventorycell22"
</TableRow>
<TableRow>
<TextView
android:id="@+id/inventorycell30"
<TextView
android:id="@+id/inventorycell31"
<TextView
android:id="@+id/inventorycell32"
</TableRow>
<TableRow>
<TextView
android:id="@+id/inventorycell40"
<TextView
android:id="@+id/inventorycell41"
<TextView
android:id="@+id/inventorycell42"
</TableRow>
</TableLayout>
Is there any way of referring to the TextViews in code, without having to id them individually. I was thinking there might be come way of getting row/col views from the tableview.
-Frink