Hinzufügen-Taste, um jede Zeile in listview

Möchte ich hinzufügen-Taste, um jede Zeile meiner listview. Ich habe eine XML-Datei namens row.xml in meinem layout Ordner Hinzugefügt und zwei textviews und eine Schaltfläche in die Datei. Aber, wenn eine Schaltfläche Hinzugefügt, ich bin nicht in der Lage, um auf das Element listview. Ich bin nur in der Lage, klicken Sie auf die Schaltfläche. Hier ist row.xml:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    >


    <TextView
        android:id="@+id/text11"

        android:layout_alignParentLeft="true"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
  android:textSize="25sp"
  android:textColor="#000000"
         />
          <TextView
        android:id="@+id/text2"

        android:layout_alignParentLeft="true"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
  android:textSize="10sp"
    android:textColor="#000000"
         />
          <Button android:text="Button" android:id="@+id/button1" android:layout_width="wrap_content" android:layout_height="wrap_content"></Button>
</LinearLayout>

Möchte ich verweisen auf textviews und Taste in meiner Tätigkeit. Bitte helfen Sie mir und schlagen Ihnen einige Ideen.

InformationsquelleAutor hussain | 2011-09-06

Schreibe einen Kommentar