# Quick question about the XML photo gallery tutorial

**URL:** <https://forum.kirupa.com/t/quick-question-about-the-xml-photo-gallery-tutorial/162270>\
**Category:** flash\
**Created:** [September 11, 2005, 5:27pm UTC](https://forum.kirupa.com/t/quick-question-about-the-xml-photo-gallery-tutorial/162270 "2005-09-11T17:27:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![aphex\_twin](https://avatars.discourse-cdn.com/v4/letter/a/73ab20/32.png) [@aphex\_twin](https://forum.kirupa.com/u/aphex_twin)\
**Post date:** [September 11, 2005, 5:27pm UTC](https://forum.kirupa.com/t/quick-question-about-the-xml-photo-gallery-tutorial/162270/1 "2005-09-11T17:27:40Z")

</div>

Hi guys, I’m a flash newbie so please forgive me 😉

Just wanted to ask how to make the “next” button loop back to the first image when it reaches the end? And the “previous” button loop to the end when at the beginning?

The tutorial I am referring to is this one: [here](http://www.kirupa.com/developer/mx2004/xml_flash_photogallery.htm)

Thanks!
