you need viewpager
http://android-developers.blogspot.com/2011/08/horizontal-view-swiping-with-viewpager.html http://developer.android.com/reference/android/support/v4/view/ViewPager.html 2012/1/24 Oliviu Vais <[email protected]> > I thought it's clear enough. I have a HorizontalScrollView at the > bottom of my screen. I want to scroll it left and right by using 2 > buttons that are on each side(one for left scroll, one for right). I > do not need help in setting the Xml. I need help for the Java class, i > cant get my buttons to scroll continous, they scroll only once when i > click them. I need them to scroll to the end of the View but not at > once, in little continous steps. This is what i have so far: > > public boolean onTouch(View v, MotionEvent event) { > // TODO Auto-generated method stub > switch(v.getId()){ > case R.id.bRight: > sw.smoothScrollBy(20, 0); > break; > case R.id.bLeft: > sw.smoothScrollBy(-20, 0); > break; > } > return false; > > On Jan 24, 9:42 pm, Marcelo Henrique <[email protected]> wrote: > > xml logcat > > > > <?xml version="1.0" encoding="utf-8"?> > > <ScrollView android:id="@+id/ScrollView02" > > > > android:layout_width="wrap_content" > > > > android:layout_height="wrap_content" > > > > xmlns:android="http://schemas.android.com/apk/res/android"> > > <HorizontalScrollView android:id="@+id/HorizontalScrollView01" > > > > android:layout_width="wrap_content" > > > > android:layout_height="wrap_content"> > > <ImageView android:id="@+id/ImageView01" > > > > android:src="@drawable/pic" > > > > android:isScrollContainer="true" > > > > android:layout_height="fill_parent" > > > > android:layout_width="fill_parent" > > > > android:adjustViewBounds="true"> > > </ImageView> > > </HorizontalScrollView> > > </ScrollView> > > > > 2012/1/24 TreKing <[email protected]> > > > > > > > > > > > > > > > > > > > > > On Mon, Jan 23, 2012 at 9:18 AM, Oliviu Vais <[email protected] > >wrote: > > > > >> What am i doing wrong? > > > > > Well you didn't really explain what the problem is. "I'm trying to do > X" > > > is not a problem. > > > > > What have you debugged and learned so far? What is actually not > working? > > > > > > --------------------------------------------------------------------------- > ---------------------- > > > TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago > > > transit tracking app for Android-powered devices > > > > > -- > > > You received this message because you are subscribed to the Google > > > Groups "Android Developers" group. > > > To post to this group, send email to > [email protected] > > > To unsubscribe from this group, send email to > > > [email protected] > > > For more options, visit this group at > > >http://groups.google.com/group/android-developers?hl=en > > > > -- > > - Marcelo Henrique - > > "Se não puder se destacar pelo talento, vença pelo esforço." (Dave > > Weinbaum) > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- - Marcelo Henrique - "Se não puder se destacar pelo talento, vença pelo esforço." (Dave Weinbaum) -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

