views:

5423

answers:

4

How to make the ListView transparent in android?

The background android screen image should be visible.

+4  A: 

android:background="@drawable/bg"

android:cacheColorHint (#00000000)

Jacky
A: 
  • How to make the ListView transparent in android?

    As Jacky mentioned, setting attributes for list view will do the job.
    android:background="#00000000"
    android:cacheColorHint="#00000000"

  • The background android screen image should be visible.

    In Android manifest file add following attribute to activity.
    android:theme="@android:style/Theme.Dialog"

bhatt4982
+12  A: 

You should use the more verbose

android:background="@android:color/transparent"
Matthias
A: 

wow.. thanks a lot.... worked for me..

I had a custom adapter for List, and when i scrolled, it used to show a black background... and adding

android:background="#00000000" android:cacheColorHint="#00000000"

fixed my problem.

Amith GC
this should be a comment. Stackoverflow will allow to comment on questions once you get a certain amount of reputation.
Janusz
sorry.... new here...
Amith GC