简体   繁体   中英

How to add a textview between listitems of listview?

I need to add a textview in a listview in between listitems. How can i make it possible.

I have a listview with listitems and i would like to add a textview as a separator between a group of listitems list like a group.

Thanks in advance.

You should use 2 types of xml files for list items - first for "usual" list item ant second for item with textview. And set them in adapter appropriately.

You can have a look at this post. It is basically the same as grouping items with headers except you will have each item with its "header".

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM