# Trying to use "for" loop for slideshow

**URL:** <https://forum.kirupa.com/t/trying-to-use-for-loop-for-slideshow/73408>\
**Category:** Uncategorized\
**Created:** [December 15, 2004, 11:59pm UTC](https://forum.kirupa.com/t/trying-to-use-for-loop-for-slideshow/73408 "2004-12-15T23:59:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![puttytatpink](https://avatars.discourse-cdn.com/v4/letter/p/3d9bf3/32.png) [@puttytatpink](https://forum.kirupa.com/u/puttytatpink)\
**Post date:** [December 15, 2004, 11:59pm UTC](https://forum.kirupa.com/t/trying-to-use-for-loop-for-slideshow/73408/1 "2004-12-15T23:59:30Z")

</div>

Hi,  
I am trying to publish a slide show and loved your tutorial online to help- but I want the slideshow to automatically sequence thru pictures and I am trying to use a “for” loop but I don’t think I am placing the code very well. Could you help?

this is what I have for the “for” loop- but not sure how to place it

//for loop to sequence thru pics  
for(i=0; i\<this.pArray.length; i++) {  
this.changePhoto(i);  
};

thanks for you help. Blythe
