Loop preset pages

Would it be possible to implement a loop on the page navigation? So that pressing ‘next page’ on the last page of a preset loops you back to the first page, and vice versa.