You can just call setContentView() with some other view, then replace
it with a listview again once you have items to show.


On Wed, Aug 19, 2009 at 6:42 AM, Eurig Jones<[email protected]> wrote:
>
> Thanks Mark.
>
> Yeah, I saw that in the docs but I'm using a non-custom List, I have
> no custom layout and I don't intend to create one. How could I specify
> an empty view if my list returns no records?
>
> On Aug 19, 11:24 pm, Mark Murphy <[email protected]> wrote:
>> Eurig Jones wrote:
>> > Does anyone know if it's possible to show a "Currently have no items"
>> > type view in a ListActivity when, obviously, you have no items?
>>
>> http://developer.android.com/reference/android/app/ListActivity.html
>>
>> "Optionally, your custom view can contain another view object of any
>> type to display when the list view is empty. This "empty list" notifier
>> must have an id 'android:empty'. Note that when an empty view is
>> present, the list view will be hidden when there is no data to display."
>>
>> --
>> Mark Murphy (a Commons 
>> Guy)http://commonsware.com|http://twitter.com/commonsguy
>>
>> Need Android talent? Ask on HADO!http://wiki.andmob.org/hado
> >
>

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to