开发者

Remove default group header icon of Expandable listview

I am not able to remove Group header icon of Expandable listview,can anybody tell me how to set it to null in xml..

Update

<ExpandableListView android:id="@+id/elist"
    android:layout_marginTop="1dip" android:layout_weight="1"
    android:layout_width="fill_parent" android:layout_height="wrap_content"
    android:fastScrollEnabled="true" android:scrollbarSize="4dip"
 开发者_开发技巧   android:smoothScrollbar="true" android:scrollbars="horizontal"
    android:groupIndicator="@null" />

and my Group header i am Using following xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="horizontal" android:layout_width="fill_parent"
    android:layout_height="wrap_content">
    <ImageView android:id="@+id/ImageView01"
        android:layout_height="wrap_content" android:src="@drawable/zimbabwe"
        android:layout_width="wrap_content"
        android:layout_marginLeft="10dip">
    </ImageView>
    <TextView android:id="@+id/childname"
        android:paddingLeft="35dip" android:textSize="16dip"
        android:layout_width="fill_parent" android:layout_height="wrap_content" />
</LinearLayout>

but its not working for me

My SimpleExpandableListAdapter is:

SimpleExpandableListAdapter expListAdapter = new SimpleExpandableListAdapter( this, 
        createBetGroupList("spot"), 
        R.layout.group_row, new String[] { "BetGroup" }, 
        new int[] { R.id.childname }, createBetChildList("spot") , 
        R.layout.child_row, new String[] { "betText","betRate","betID" }, 
        new int[] { R.id.txtBetText, R.id.txtdecRate,R.id.txtstrBetID} );


You should set in your layout xml file the groupIndicator to null:

<ExpandableListView [...] 
    android:groupIndicator="@null" />
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜