I'm working on the android app. In my app i want to move from first activity to second activity by swiping and by click on the tab button.

so please tell me how i can use the swipe in my app for moving to next activity when i swap from Right to left and come back on first activity when i swap Left to right.

Thanks.