How to use Window Object ResizeBy in JavaScript

In this article I am going to explain about window object resizeBy() method in JavaScript.
  • 1289

JavaScript Window Object ResizeBy() Method

JavaScript ResizeBy() Method use for resize to the window. Size of window set by defined the size value of window. If you click on resize button two time then window size will be increase on two time.

Syntax

 

resizeBy(width, height)

Example

<html>

<head>

    <script type="text/javascript">

        var w;

        function Winopen() {

            w = window.open('', '', 'width=150,height=75');

            w.focus();

        }

 

        function myfun() {

            w.resizeBy(150, 100);

            w.focus();

        }

 

    </script>

</head>

<body>

    <button onclick="Winopen()">

        open win</button>

    <button onclick="myfun()">

        Resize Win</button>

</body>

 

Output


resizeby1.gif


After Click button


resizeby2.gif

 

You may also want to read these related articles: here
 
Ask Your Question 
 
Got a programming related question? You may want to post your question here
 

Categories

More Articles

© 2013 dotNetheaven. All rights reserved.