I have a GridView
of more than 10 rows. That is a reference chart so the user is unable to scroll manually. The GridView
should be scroll down in a particular time period. What I have to do for that? Is it possible to make a GridView
with only smoothscroll? One more Question i have is that.
how can we access gridview from adapter class.?
Asked
Active
Viewed 907 times
1

Aaloka
- 115
- 2
- 11
-
i havnt tried anything because i dont know what i have to do.. – Aaloka May 09 '13 at 11:57
2 Answers
2
I have solved the disabling of gridview scroll by
gridView.setOnTouchListener(new OnTouchListener(){
@Override
public boolean onTouch(View v, MotionEvent event)
{
if(event.getAction()==MotionEvent.ACTION_MOVE){ return true; }
return false; } });

Aaloka
- 115
- 2
- 11
0
You could use AlarmManager
to schedule that time period for a method like that:
public void bringListDown(){
int position = yourGridView.getCount();
yourGridView.setSelection(position);
}
This gonna bring your gridView to the bottom;

Guilherme Gregores
- 1,050
- 2
- 10
- 27
-
Never tried but, i THINK you can access it by the getview() of the adapter – Guilherme Gregores May 09 '13 at 13:09
-
take a look a similar question: http://stackoverflow.com/questions/10910638/get-access-to-listview-from-its-adapter – Guilherme Gregores May 09 '13 at 13:10