Simplifing私は2行のテーブルを持っています。 1つの行にTextViewがあり、もう1つの行に2つのtextViewがあります...私はandroid:layout_span = "2"を使用する必要がありますが、それはwowrkinではありません。私が持っている resutlこのXamarin Android TableRow android:layout_span = 2
そして、私のコードのようなものです私は一列にタイトルを必要とするこの
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<TableLayout
android:id="@+id/tableLayout1"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<TableRow
android:gravity="center_horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:layout_span="2"
android:layout_width="300sp"
android:gravity="center"
android:textSize="11sp"
android:id="@+id/Orden"
android:textStyle="bold"
android:text="MY PORTATIL BATERIY 9V VRef>8,7V" />
</TableRow>
<TableRow
android:gravity="center_horizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:gravity="center"
android:textSize="10sp"
android:id="@+id/Orden"
android:text="V Med" />
<TextView
android:gravity="center"
android:textSize="10sp"
android:id="@+id/Orden"
android:text="Venc Batery" />
</TableRow>
</TableLayout>
</LinearLayout>
</FrameLayout>
のようなものです。 私が紛失しているものは? ありがとうございますか?
これは同じ結果です...それは3行で表示されます。それは、そのように2番目のtableRowの幅で幅のレイアウトを修正するようです。 – Diego
@Diego私はあなたの 'TableLayout'定義を見逃してしまったので答えを更新しました – SushiHangover