This my xml file that shows listview under linerlayout and scrollview. How can I make my listview scroll? Because what I wanted is the background image under the linearlayout is scrolling too. But whenever I wanted to scroll the listview it rather scroll the whole layout.
<ScrollView 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"
tools:context=".MainScreenEntered"
>
<LinearLayout
android:layout_width="320dp"
android:layout_height="wrap_content"
android:orientation="vertical"
android:background="@drawable/mainscreen"
>
<EditText
android:id="@+id/txtSearch"
android:layout_width="220dp"
android:layout_height="40dp"
android:layout_marginLeft="30dp"
android:layout_marginRight="10dp"
android:layout_marginTop="130dp"
android:background="@drawable/white"
android:height="10dp"
android:singleLine="true"
android:textSize="15sp"
android:hint="@string/search"
/>
<Button
android:layout_width="45dp"
android:layout_height="45dp"
android:layout_marginLeft="250dp"
android:layout_marginRight="10dp"
android:layout_marginTop="-41dp"
android:background="@drawable/btnsearch"
/>
<ListView
android:id="@+id/lvEntries"
android:layout_width="255dp"
android:layout_height="300dp"
android:layout_marginLeft="30dp"
android:layout_marginRight="10dp"
android:layout_marginTop="41dp"
/>
<Button
android:layout_width="280dp"
android:layout_height="55dp"
android:layout_marginLeft="20dp"
android:layout_marginRight="10dp"
android:layout_marginTop="21dp"
android:background="@drawable/btnaddentry"
android:onClick="goToAddEntryScreen"
/>
</LinearLayout>
</ScrollView>