0
我添加滚动后我尝试更改滚动视图的高度 列表中的scrollview
列表,因此列表位于布局的中心并且高度更大但它不起作用。带有滚动视图的列表
我添加滚动后我尝试更改滚动视图的高度 列表中的scrollview
列表,因此列表位于布局的中心并且高度更大但它不起作用。带有滚动视图的列表
ListView
是可滚动的。您不能将ListView
放入ScrollView
之内。
你在哪里读到的ListView滚动型扩展尝试的代码
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="@drawable/bg_all_1" >
<LinearLayout
android:id="@+id/bottom_menu"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:orientation="vertical" >
</LinearLayout>
<include
android:id="@+id/top_header"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_marginLeft="40dp"
android:layout_marginTop="91dp"
layout="@layout/layout_header" />
<include
android:id="@+id/footer"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/bottom_menu"
android:layout_alignParentLeft="true"
android:layout_marginBottom="40dp"
layout="@layout/layout_footer" />
<ListView
android:id="@android:id/list"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_above="@+id/footer"
android:layout_below="@+id/top_header"
android:layout_centerHorizontal="true" >
</ListView>
</RelativeLayout>
这个样本? – Blackbelt
噢,我的,你是对的。对不起。但它是可滚动的,它无法在ScrollView中正常工作^^' – Agata
你确定吗?那么我可以改变它的高度呢?告诉我我该怎么做:( – sara