var scrollspeed=1;
var cache=1;
var x;
var vTimeOut=0; 

  function initialize(){
  marqueeheight=parent.document.getElementById("datamain").getAttribute("height");
  scrolltest();
  }

  function waitMoment(x){
   if (x==1)
    initialize();
   else 
    setTimeout("waitMoment(1)",1000);
  }

  function scrolltest(){
  if(vTimeOut)
    window.clearTimeout(vTimeOut);
  dataobj.style.top=parseInt(dataobj.style.top)-scrollspeed;
  if (parseInt(dataobj.style.top)<(thelength*(-1)))
   dataobj.style.top=5
  vTimeOut=setTimeout("scrolltest()",80);
  }

  window.onload=waitMoment

function newWin(url,width,height)
{
var tWin=window.open(url,'','toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,movable=yes,resizable=yes,width='+width+',height='+height);
}


var scrollFlag=true;
var x;

function StopTicker(){
 scrollflag=false;
 window.clearTimeout(x);
}

function setTicker()
{ 
 scrollflag=true;
 scrollDiv();
}

function scrollDiv() {
       if (scrollFlag)
        { 
    	 var sDiv=document.getElementById("FirstDiv")
      	 sDiv.style.top = parseInt(sDiv.style.top)-1
    	 if(parseInt(sDiv.style.top) < -sDiv.offsetHeight) sDiv.style.top = 40;
             window.clearTimeout(x); 
    	 x=setTimeout("scrollDiv()",125);    
        }

}
function startScroll()	{
	var sDiv=document.getElementById("FirstDiv");
	sDiv.style.top =40;
}
