我有代碼簡單的XML佈局是這樣的:佈局與ArrayAdapter和其他部件
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="ARRAYADAPTER" />
<ListView
android:id="@+listview/lw"
android:layout_width="match_parent"
android:layout_height="wrap_content" >
</ListView>
<Button
android:id="@+button/b1"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:text="NEXT"
android:gravity="center"/>
</LinearLayout>
,並設置列表視圖裏的數組適配器。當我啓動這個應用程序時,buttod不會出現。 我想要做的是將佈局分爲三部分: -textview頂部 - 中間的適配器(滾動) - 按鈕(或多個)到底部。 我該怎麼做?
正確!我總是出現錯誤的參數! – giozh 2013-03-05 20:04:16