I am never using this but this is helps you.
使drawable/table_shape.xml
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android="http://schemas.android.com/apk/res/android"
android:shape= "rectangle" >
<solid android:color="#000"/>
<stroke android:width="1dp" android:color="#ff9"/>
</shape>
布局/my_table.xml
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TableRow android:id="@+id/tabla_cabecera" android:layout_width="match_parent" android:layout_height="match_parent"></TableRow>
<TableLayout android:id="@+id/tabla_cuerpo" android:layout_height="match_parent" android:layout_width="match_parent">
<TableRow android:id="@+id/tableRow1" android:layout_width="match_parent" android:layout_height="wrap_content">
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
</TableRow>
<TableRow android:id="@+id/tableRow2" android:layout_width="match_parent" android:layout_height="wrap_content">
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView></TableRow>
<TableRow android:id="@+id/tableRow3" android:layout_width="match_parent" android:layout_height="wrap_content">
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
</TableRow>
<TableRow android:id="@+id/tableRow4" android:layout_width="match_parent" android:layout_height="wrap_content">
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
<TextView android:background="@drawable/cell_shape" android:padding="5dp" android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textAppearance="?android:attr/textAppearanceMedium" android:text="TextView"></TextView>
</TableRow>
</TableLayout>
</RelativeLayout>