Great! That works. I would like to show a textview at the top of the list (saying something like "Select the item"). I followed an example, but I can only see it say "No data". I have changed my code by adding setContentView(R.layout.mylistact), and this is what mylistact.xml looks like:
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/ android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:paddingLeft="8dp" android:paddingRight="8dp"> <TextView android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="Select the item" /> <ListView android:id="@id/android:list" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1" android:drawSelectorOnTop="true" /> <TextView id="@id/android:empty" android:layout_width="fill_parent" android:layout_height="fill_parent" android:text="No data" /> </LinearLayout> Any ideas? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

