
var show = 0;
var Direction = 0;
var active = 0;

function Switch_Images(Direction)
	{
	show = show + Direction;
	if(show == -1) show = Number - 1;		
	if(show == Number) show = 0;
	document.LoopImage.src = Images[show].src;
	document.getElementById("Caption").firstChild.nodeValue = Captions[show];
	}	
	
function Auto_Loop()
	{
	if(active == 0)
		{
		run = window.setInterval("Switch_Images(1)",500);
		active = 1;
		}
	}

function Stop_Loop()
	{
	window.clearInterval(run);
	active = 0;
	}



