  var intervalUp = null;
  var intervalDown = null;
  var object = null;
  
  //interval methods
  function moveIntervalUp(){
	document.getElementById(object).scrollTop -= 1;
	/*
          alert(document.getElementById('scrolled').scrollLeft); //scrollHeight questo restituisce solo l'altezza della bar
	document.getElementById('scrollheight').innerText = document.getElementById('scrolled').scrollHeight;
	document.getElementById('scrolltop').innerText = document.getElementById('scrolled').scrollTop;
	//scrollTop restituisce la posizione precisa della casella di scorrimento
	*/
  }
  
  function moveIntervalDown(){
	document.getElementById(object).scrollTop += 1;
  }
	
	//Stop call methods
  function stopScroll(){
	if(intervalUp){
	  clearInterval(intervalUp);
	  intervalUp = null;
	}
	if(intervalDown){
	  clearInterval(intervalDown);
	  intervalDown = null;
	}
	
	object = null;
  }
  
  //call methods
  function moveUp(obj){
	object = obj;
	intervalUp = setInterval("moveIntervalUp()",5);
  }
  
  function moveDown(obj){
	object = obj;
	intervalDown = setInterval("moveIntervalDown()",5);
  }
  
  //function that scroll content directly to 10 unit
  function moveUpDirect(obj){
  
  }
  
  function moveDownDirect(obj){
  
  }
