function thereset(scroll,pause,speed,maxtop,objectname,startpos) {
	//alert("Reset");
	document.getElementById(objectname).style.top = startpos;
	themove(scroll,pause,speed,maxtop,objectname,startpos);
}

function themove(scroll,pause,speed,maxtop,objectname,startpos) {

	//alert ("scroll: " + scroll + " | pause: " + pause + " | speed: " + speed+ " | maxtop: " + maxtop+ " | objectname: " + objectname);

	element = document.getElementById(objectname);
	
  //alert (parseInt(element.style.top));
  
  element.style.top = (parseInt(element.style.top) - 1) + "px";
	
	
	if (parseInt(element.style.top) <= maxtop) {

		window.setTimeout("thereset(scroll,pause,speed,maxtop,objectname,startpos)", pause);

	} else {

		if (parseInt(element.style.top) % scroll == 0) {
			window.setTimeout("themove(scroll,pause,speed,maxtop,objectname,startpos)", pause);
		} else {
			window.setTimeout("themove(scroll,pause,speed,maxtop,objectname,startpos)", speed);
		}

	}

}