Skip to content Skip to sidebar Skip to footer

How To Set Height And Width Of A New Window From Code Behind

I have been trying this from hours that I am opening a new window and I am bound to launch from code behind so it is not opening in new tab. I want to adjust the height and width o

Solution 1:

Try this

note 2nd parameter is name of window. the height and width you need to give in 3rd parameter

functionOpenWindow() {
        window.open('../ReportWebForm.aspx?ReportType=Report','', 'width = 100, height = 100');
    }

Solution 2:

You can try this.

<ahref="javascript:;"style="color:#000"onClick="window.open('printreport3.php','msgWindow','toolbar=no, scrollbars=yes, resizable=no, top=30, left=100, width=1000, height=auto')"> Print View </a>

you have to set scrollbar to yes. scrollbars=yes

Post a Comment for "How To Set Height And Width Of A New Window From Code Behind"