# Scroller - slideshow (connection)

**URL:** <https://forum.kirupa.com/t/scroller-slideshow-connection/187479>\
**Category:** Uncategorized\
**Created:** [April 29, 2006, 4:17pm UTC](https://forum.kirupa.com/t/scroller-slideshow-connection/187479 "2006-04-29T16:17:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![tonni](https://avatars.discourse-cdn.com/v4/letter/t/9fc348/32.png) [@tonni](https://forum.kirupa.com/u/tonni)\
**Post date:** [April 29, 2006, 4:17pm UTC](https://forum.kirupa.com/t/scroller-slideshow-connection/187479/1 "2006-04-29T16:17:50Z")

</div>

Hi guys -

How can I make my gallery work?

Initially I have a menu (scroller-voetsjoeba) in where I say

for(var i=0;i\<\_global.gallery\_xml.firstChild.childNodes.length;i++){  
menumc=menucontainer.attachMovie(“menuButton”,“button\_mc”+i,i);  
menumc.id = i;

menumc.onRelease = function(){  
\_root.picture.loadMovie(gallery\_xml.firstChild.childNodes[this.id].childNodes[0].attributes.source);

and so far it works fine - I get my firstImage…

I can also get the slideshow to work but not as intended, only in the first category “life”, and that’s really my problem…

How can I make the slideshow work accordingly to my xml file, so that if I click a menubutton in the scroller it correspondes with the correct id and so on?

\<?xml version=“1.0” encoding=“UTF-8”?\>  
\<menu\>  
\<gallery name=“life”\>  
\<image source=“gallery/1.jpg”/\>  
\<image source=“gallery/2.jpg”/\>  
\<image source=“gallery/3.jpg”/\>  
\<image source=“gallery/4.jpg”/\>  
\<image source=“gallery/5.jpg”/\>  
\<image source=“gallery/6.jpg”/\>  
\</gallery\>  
\<gallery name=“mood”\>  
\<image source=“gallery/11.jpg”/\>  
\<image source=“gallery/12.jpg”/\>  
\<image source=“gallery/13.jpg”/\>  
\<image source=“gallery/14.jpg”/\>  
\<image source=“gallery/15.jpg”/\>  
\<image source=“gallery/16.jpg”/\>  
\</gallery\>  
\<gallery name=“special”\>  
\<image source=“gallery/21.jpg”/\>  
\<image source=“gallery/22.jpg”/\>  
\<image source=“gallery/23.jpg”/\>  
\<image source=“gallery/24.jpg”/\>  
\<image source=“gallery/25.jpg”/\>  
\<image source=“gallery/26.jpg”/\>  
\</gallery\>  
\<gallery name=“etcetera”\>  
\<image source=“gallery/31.jpg”/\>  
\<image source=“gallery/32.jpg”/\>  
\<image source=“gallery/33.jpg”/\>  
\<image source=“gallery/34.jpg”/\>  
\<image source=“gallery/35.jpg”/\>  
\<image source=“gallery/36.jpg”/\>  
\</gallery\>  
\</menu\>

… I’d be really greatfull - if someone could help me.

thank you for your time - Tonni.
