200 questions
358 votes
26 answers
252k views
How can I put a ListView into a ScrollView without it collapsing?
I've searched around for solutions to this problem, and the only answer I can find seems to be "don't put a ListView into a ScrollView". I have yet to see any real explanation for why though. The ...
921 votes
32 answers
736k views
Making TextView scrollable on Android
I am displaying text in a TextView that appears to be too long to fit into one screen. I need to make my TextView scrollable. How can I do that? Here is the code: final TextView tv = new TextView(this)...
294 votes
34 answers
339k views
Android list view inside a scroll view
I have an android layout which has a scrollView with a number of elements with in it. At the bottom of the scrollView I have a listView which is then populated by an adapter. The problem that I am ...
343 votes
26 answers
288k views
RecyclerView inside ScrollView is not working
I'm trying to implement a layout which contains RecyclerView and ScrollView at the same layout. Layout template: <RelativeLayout> <ScrollView android:id="@+id/myScrollView"> ...
228 votes
9 answers
137k views
HorizontalScrollView within ScrollView Touch Handling
I have a ScrollView that surrounds my entire layout so that the entire screen is scrollable. The first element I have in this ScrollView is a HorizontalScrollView block that has features that can be ...
96 votes
13 answers
131k views
Detect end of ScrollView
I have an app, that has an Activity that uses a ScrollView. I need to detect when user gets to the bottom of the ScrollView. I did some googleing and I found this page where is explained. But, in the ...
117 votes
19 answers
161k views
Disable ScrollView Programmatically?
I would like to enable ScrollView and disable it by a Button Click. Disable means like if the ScrollView wasn't there, and enable it returns the ScrollView. I want that because I have a gallery with ...
160 votes
19 answers
196k views
Can I scroll a ScrollView programmatically in Android?
Is there any way to scroll a ScrollView programmatically to a certain position? I have created dynamic TableLayout which is placed in a ScrollView. So I want that on a specific action (like clicking ...
243 votes
19 answers
198k views
Android: ScrollView force to bottom
I would like a ScrollView to start all the way at the bottom. Any methods?
193 votes
19 answers
126k views
Recyclerview inside ScrollView not scrolling smoothly
For my app I am using a RecyclerView inside a ScrollView where the RecyclerView has a height based on its content using this library. Scrolling is working but it's not working smoothly when I scroll ...
93 votes
1 answer
150k views
Scrollview can host only one direct child [duplicate]
I have multiple LinearLayouts with a combined height that easily exceeds a device's screen height. So in order to make my layout scrollable, I tried adding in a ScrollView, but unfortunately I get the ...
85 votes
8 answers
136k views
How can I make my layout scroll both horizontally and vertically?
I am using a TableLayout. I need to have both horizontal and vertical scrolling for this layout. By default I am able to get vertical scrolling in the view but horizontal scrolling is not working. I ...
100 votes
16 answers
107k views
Recyclerview Changing Items During Scroll
I have a RecyclerView. Each row has a play button, textview and Progressbar. when click on the play button have to play audio from my sdcard and have to progress Progressbar The problem is when i ...
67 votes
13 answers
75k views
Android Keyboard hides EditText
When I try to write something in an EditText which is at the bottom of the screen, the soft keyboard hides the EditText. How can I resolve this issue? Below is my xml code. I'm using this in a ...
35 votes
5 answers
36k views
Dynamic height viewpager
I'm trying to create a custom viewpager inside custom scroll viewthat dynamically wraps the current child's height. package com.example.vihaan.dynamicviewpager; import android.content.Context; ...