I am very new to Android development and so I am seeking advice for the best means to implement the following…
I would like to display a few famous sayings in an app – one page at a time, with back and next button navigating to the previous and next sayings. Just like below…

For this…
- Do I have to create a separate
Activitywith itsLayoutfor each page (famous quote screen)? (If there are 20 quotes then do I have to create 20 Activities?) - If yes to question 1, then do I need dedicated “Back” and “Next” buttons for each page? (Is there any way of using the same back & next buttons globally)?
Any advice is greatly appreciated.
Use
ViewPagerandFragments. This way you don’t have to create separateActivitys andLayouts. You just had separate pages for each new screen. You also won’t have to create new buttons for each page.Check out the Docs about getting started with it
This tutorial is a good one to see how to use
ViewPager. It steps you through using it and has source code that you can download and tailor to what you need it for. This is a good way to keep theLayouts consistent with less code which is probably what you would want for something like this