// JavaScript Document

<!-- Original:  D. Keith Higgs (dkh2@po.cwru.edu) -->

<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->

var timeDelay = 2; // change delay time in seconds
var Pix = new Array ("images/office/rs_reception.jpg",
					 "images/office/rs_consult.jpg",
					 "images/office/rs_op.jpg");
var howMany = Pix.length;
timeDelay *= 1000;
var PicCurrentNum = 0;
var PicCurrent = new Image();
PicCurrent.src = Pix[PicCurrentNum];

function startPix() {
	setInterval("slideshow()", timeDelay);
}

function slideshow() {
	PicCurrentNum++;
	if (PicCurrentNum == howMany) {
		PicCurrentNum = 0;
	}
	PicCurrent.src = Pix[PicCurrentNum];
	document["ChangingPix"].src = PicCurrent.src;
}
