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 a Button, etc.) the particular row should scroll automatically to a top position.
Is it possible?
ScrollView sv = (ScrollView)findViewById(R.id.scrl);
sv.scrollTo(0, sv.getBottom());
or
sv.scrollTo(5, 10);