'scrollHeight' Example : scrollHeight : Javascript Properties : JavaScript Reference examples (example source code) Organized by topic

JavaScript Reference
C++
PHP
JavaScript Reference Home »  Javascript Properties   » [  scrollHeight  ]   
 



'scrollHeight' Example

    
<html>
<body>
<script language="JavaScript">
function function2() {
    mySH.innerHTML = myDiv.scrollHeight;
    mySW.innerHTML = myDiv.scrollWidth; 
}
</script>
<p>
   <b>Scroll Height:</b> 
   <span id="mySH">0</span>
</p>
<p>
   <b>Scroll Width:</b> 
   <span id="mySW">0</span>
</p>
<div id="myDiv" 
     onmousemove="function2();" 
     onscroll="function1();" 
     style="border:solid; width:200; height:50; overflow:scroll;">
   <img src="yourimage.gif">
</div>
</body>
</html>

    
      
      
Related examples in the same category
1.  'scrollHeight' Syntax and Note
2.  'scrollHeight' is applied to
























Home| Contact Us
Copyright 2003 - 04 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.