<!DOCTYPE html>
<html lang="en-US">
<head>
<style>
div{
width:100px;
height:100px;
font-size:17px;
border:1px solid #8c8c8c;
margin-bottom:70px;
}
</style>
</head>
<body>
<div id="point">
This div contains lots of text, but the height of this div is 100px, whereas, width of this div is 100px.
</div>
<button onclick="myFunction()">Click Me</button>
<script>
function myFunction(){
var x = document.getElementById("point");
x.style.overflowY = "scroll";
}
</script>
<p><strong>Note</strong>: Click on the button to change the div from overflow-y visible to scroll.</p> </body>
</html>