I am working on Android Widget my widget is like following diagram, [prev] event name [next]
prev, next are the buttons on the widget.So i want to update the event name on click of next and prev button.On start of the service i loaded the data and stored it in array list. Now i want to iterate through the array list by clicking the next and prev buttons on the widget.
So how can i achieve this.Please help me with proper solution. Here is my xml layout
<LinearLayout
android:id="@+id/lytWidget2"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dip"
android:orientation="horizontal" >
<Button
android:id="@+id/btnPreviousView"
android:layout_width="43dp"
android:layout_height="fill_parent"
android:layout_gravity="left|center"
android:background="@drawable/ic_leftarrow"
android:padding="5dip" />
<TextView
android:layout_width="wrap_content"
android:layout_height="52dp"
android:layout_weight="0.97"
android:text="Event Name" />
<Button
android:id="@+id/btnNextView"
android:layout_width="43dp"
android:layout_height="fill_parent"
android:layout_gravity="right|center_vertical"
android:background="@drawable/ic_rightarrow"
android:padding="5dip" />
</LinearLayout>