Heres a similar thing i did with a list view, with a button at the bottom and a spinner at the top, you might be able to modify it to suit your app. XML layout:
<?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:orientation="vertical">
<RelativeLayout android:layout_width="fill_parent"
android:layout_height="wrap_content" android:id="@+id/top_control_bar">
<Spinner android:id="@+id/sort_by" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:entries="@array/default_sorts" />
</RelativeLayout>
<LinearLayout android:id="@+id/bottom_control_bar"
android:layout_width="fill_parent" android:layout_height="wrap_content"
android:layout_alignParentBottom="true">
<Button android:layout_width="fill_parent"
android:layout_height="wrap_content" android:text="Add Item" />
</LinearLayout>
<ListView android:id="@android:id/list" android:layout_width="fill_parent"
android:layout_height="0dip" android:choiceMode="multipleChoice"
android:layout_below="@id/top_control_bar" android:layout_above="@id/bottom_control_bar"></ListView>
<TextView android:id="@android:id/empty" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:text="@string/main_empty_list"
android:layout_below="@id/top_control_bar"android:layout_above="@id/bottom_control_bar" />
</RelativeLayout>
Java Code:
// myList.java
package com.test.listview;
import android.app.ListActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.ListView;
public class myList extends ListActivity
{
/** Called when the activity is first created. */
public void onCreate(Bundle bundle)
{
super.onCreate(bundle);
// Create an array of Strings, that will be put to our ListActivity
String[] names = new String[] { "Linux", "Windows7", "Eclipse", "Suse",
"Ubuntu", "Solaris", "Android", "iPhone", "Linux", "Windows7",
"Eclipse", "Suse", "Ubuntu", "Solaris", "Android", "iPhone" };
setContentView (R.layout.main);
ListView listView = getListView();
ArrayAdapter a = new ArrayAdapter <String>(this, android.R.layout.simple_list_item_single_choice, names);
setListAdapter(a);
}
}
Strings.xml:
// strings.xml
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="hello">Hello World, myList!</string>
<string name="app_name">listview</string>
<string-array name="default_sorts">
<item>fooboo</item>
<item>asdfgh</item>
<item>qwerty</item>
<item>346346</item>
<item>hjkgaf</item>
<item>asdfas</item>
<item>vbncvn</item>
<item>dfgrdf</item>
<item>hjkkmb</item>
<item>fdghgv</item>
</string-array>
<string name="main_empty_list">foo</string>
</resources>