Answer the question
In order to leave comments, you need to log in
How to make a complex ListView in android?
Hello. We need to make a complex ListView, namely: it has several sections separated by a header, the item of each section has a different layout (but the same for the entire section). How to make such a listView?
In fact - you can use ExpandableListView, but is it a good option? Perhaps there is some lib that does it without it?
Answer the question
In order to leave comments, you need to log in
You need a special sheet adapter. You can act like a true programmer - write the adapter yourself. This is not difficult at all - you need to inherit from BaseAdapter and implement, in addition to the standard ones, two methods related to the types of sheet elements: getItemViewType and getViewTypeCount. You can have any number of element types. Accordingly, in the main getView method, you can choose the layout that matches the type of the requested element.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question