title: ScrollView with a ListView doesn't scroll - android
body: <p>My problem with the following layout is that the layout doesn't scroll. My requirement is that I have to display 2 lists which at times can be big. So i put both the ListViews inside a ScrollView so that i can scroll to the bottom and have a look at both the ListViews. <code>I don't want the ListView to scroll</code>. I only want my ScrollView to behave as it should. Any suggestions??</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="fill_parent"
  android:layout_height="fill_parent"
  android:orientation="vertical" &gt;
  &lt;ScrollView
          android:id="@+id/scrollViewContactDetails"
          android:layout_width="match_parent"
          android:layout_height="fill_parent" android:fillViewport="true"&gt;
  
  
          &lt;LinearLayout
              android:layout_width="fill_parent"
              android:layout_height="fill_parent"
              android:orientation="vertical" &gt;
  
  
              &lt;TextView
                  android:id="@+id/name"
                  android:layout_width="match_parent"
                  android:layout_height="wrap_content"
                  android:layout_marginLeft="10dp"
                  android:layout_marginTop="5dp"
                  android:textAppearance="?android:attr/textAppearanceLarge"
                  android:textSize="22dp" /&gt;
  
              &lt;LinearLayout
                  android:id="@+id/numbersLayout"
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:layout_marginLeft="20dp"
                  android:layout_marginRight="20dp"
                  android:orientation="vertical"
                  android:weightSum="1" &gt;
  
                  &lt;LinearLayout
                      android:id="@+id/numbersLayoutList"
                      android:layout_width="match_parent"
                      android:layout_height="fill_parent"
                      android:gravity="center"
                      android:orientation="vertical"
                      android:weightSum="1" &gt;
  
                      &lt;ListView
                          android:id="@+id/numbersList"
                          android:layout_width="match_parent"
                          android:layout_height="fill_parent"
                          android:layout_gravity="center"
                          android:dividerHeight="2dp" &gt;
                      &lt;/ListView&gt;
                  &lt;/LinearLayout&gt;
              &lt;/LinearLayout&gt;
  
              &lt;LinearLayout
                  android:id="@+id/emailLayout"
                  android:layout_width="fill_parent"
                  android:layout_height="wrap_content"
                  android:layout_marginLeft="20dp"
                  android:layout_marginRight="20dp"
                  android:layout_marginTop="10dp"
                  android:orientation="horizontal"
                  android:weightSum="1" &gt;
  
                  &lt;LinearLayout
                      android:layout_width="120dp"
                      android:layout_height="match_parent"
                      android:layout_gravity="right|center"
                      android:gravity="top|right"
                      android:orientation="vertical" &gt;
  
                      &lt;TextView
                          android:id="@+id/emailId"
                          android:layout_width="120dp"
                          android:layout_height="wrap_content"
                          android:layout_marginTop="10dp"
                          android:gravity="right|center"
                          android:textAppearance="?android:attr/textAppearanceMedium"
                          android:textColor="#8d8d8d"
                          android:textSize="18dp" /&gt;
                  &lt;/LinearLayout&gt;
  
                  &lt;LinearLayout
                      android:id="@+id/emailLayoutList"
                      android:layout_width="match_parent"
                      android:layout_height="fill_parent"
                      android:layout_marginLeft="20dp"
                      android:gravity="center"
                      android:orientation="vertical"
                      android:weightSum="1" &gt;
  
                      &lt;ListView
                          android:id="@+id/emailList"
                          android:layout_width="match_parent"
                          android:layout_height="fill_parent"
                          android:layout_gravity="center"
                          android:layout_weight="1"
                          android:dividerHeight="2dp" &gt;
                      &lt;/ListView&gt;
                  &lt;/LinearLayout&gt;
              &lt;/LinearLayout&gt;
          &lt;/LinearLayout&gt;
      &lt;/ScrollView&gt;
  &lt;/LinearLayout&gt;
  </code></pre>