Scrollview inside a scrollview in android issue

android

Solution

Try this code. It is working for me`

 parentScrollView.setOnTouchListener(new View.OnTouchListener() {

public boolean onTouch(View v, MotionEvent event)
{
    findViewById(R.id.childScrollView).getParent().requestDisallowInterceptTouchEvent(false);
return false;
}
});
childScrollView.setOnTouchListener(new View.OnTouchListener() {

public boolean onTouch(View v, MotionEvent event)
{

// Disallow the touch request for parent scroll on touch of
// child view
v.getParent().requestDisallowInterceptTouchEvent(true);
return false;
}
});`

Problem

I have a scrollview inside a scrollview . The xml is like this ``` <RelativeLayout .... <ScrollView..... <RelativeLayout .... <Button..... <Button .... <ScrollView <RelativeLayout .... .......... </RelativeLayout> </ScrollView> </RelativeLayout> </ScrollView> </RelativeLayout> ``` in this second scrollview in not scrolling smoothly. can give a solution for that. I tried a lot of solution given in the internet but not working.

Original source