Je suis en train de développer une activité dans laquelle j'utilise la vue de liste avec la disposition de la table. Je veux afficher 3 texte (à partir des valeurs de base de données MySQL) dans cette vue de la liste, mais le problème est que le texte sont affichage légèrement sur ordre de la liste commeTablelayout avec listview
Text1 Text1 Text1 Text1 Text1 Text1
Text2 Text2 Text2 and i want this Text2 Text2 Text2
Text3 Text3 Text3 Text3 Text3 Text3
cette façon .. donc une idée sur la propriété afficher la liste ou la vue de texte pour le définir correctement dans l'ordre? puis plz comment ...
List_row.xml
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:stretchColumns="1">
<TableRow
android:background="@drawable/table_row_bg"
>
<TextView
android:id="@+id/adapter_text_estate"
android:text="estate"
android:gravity="center"
android:textSize="8dp"
android:layout_marginRight="10sp"
android:padding="3dip" />
<TextView
android:id="@+id/adapter_text_division"
android:text="division"
android:gravity="left"
android:textSize="8dp"
android:padding="3dip" />
<TextView
android:id="@+id/adapter_text_id"
android:text="id"
android:textSize="8dp"
android:gravity="right"
android:padding="3dip" />
</TableRow>
</TableLayout>
Main.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#E0FFFF"
android:orientation="vertical" >
<TextView
android:id="@+id/cources_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="ESTATE NAME"
android:textColor="#429ed7"
android:textSize="12sp"
android:textStyle="bold" />
<ListView
android:id="@+id/listCollege"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:visibility="gone"
android:layout_marginTop="8dp" >
</ListView>
</LinearLayout>
merci @ Dileep .. son travail ... – Sasya
Très très bienvenu Sasya ... –