ExpandableListView inside ScrollView is showing only one item - android

When I use ExpandableListView inside ScrollView it will show only one item,It is not showing all items and also when selected items it will shows all child items.

If your parent layout contains more items. Then you have to fix the height of listview in form of some dp instead of wrap_content/match_parent, or use NestedScrollView.

Related

Recycler view cant wrap height of its children items

Am trying to use RecyclerView but it cant show all the items of its children, but i want to show all the items
The list Items were wrapped in a Linear Layout i changed it and wrapped it in a Relative layout and it solved the problem

Gridview and Expandable listview in same scrollview in Android

I want to scroll the gridview and expandable listview in same scroll. How I need to implement and which type of code I need to add for adapters. I using one method to adding these two (gridview, expandable listview in same class) but here I am facing problem with expandable listview child height. I put gridview and expandable listview height static. Expandable listview child items expand remaining top or ending group items are not displaying. Can any one suggest any best solution for this...
Thanks,
Shaik. Khaja Peer...

Android scrollview as listitem

I have a listview that has custom child items. Each list item has scrollview inside. Its not good practice to put scrollview inside listview but my requirement is like that.
Example: I have a listview and date picker kind of view has child element. Now how do I scroll the child views in each list item?
Instead of using a ScrollView as a row item within a ListView try using ExpandableListView

How can i add a Expandable listview to the end of a page in a scrollview?

I need to place an expandable listview to the end of a page that displays some data in a scrollview. Basically the listview contains some user comments for the page. The page contains a lot of dynamic data so that it can be placed in a scrollview only. When i add an expandable listview to the end of the scrollview it falls in the right position. But when i expand the listview & set the parent view to wrap height, a part of the listview get clipped of. How can i handle this. I have tried setting the layoutparams of Parent view to wrap content. But that doesnt work.
PS: The cell sizes of the expandable list items is variable.
EDIT: The structure of my xml is
ScrollView
LinearLayout
Comments layout is inflated here along with some other layouts
Comment layout is
LinearLayout
Expandablelistview
I am tring to set the sizes of parent layout dynamically after calculating in onExpanded & collapsed

Not scrollable listview in scroll view android

i need to make a layout that is scrollable, holds a listview that is not scrollable(full height of the content). So when i scroll the content above the listview is showed, and the full listview is displayed.
Is this possible in android?
what do you mean by ListView ( not scrollable).. will it have predefined items(count) ?
you can have a <ScrollView></ScrollView> inside of which a normal(linear/relative layout say id insidelayout1)
For single item of your ListView, create a separate xml(say item.xml) and try to inflate item.xml into insideLayout1.
Will that work for you.. or detail out your requirement...
If you want to put list view inside the scroll view than you have to fix the height of list view.
otherwise you can't scroll it properly.

Categories

Resources