ASP.NET

Moderators: None (Apply to moderate this forum)
Number of threads: 1735
Number of posts: 3309

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
how to maximize the browser window of an asp.net application Posted by v_j_latha on 8 Oct 2004 at 11:53 PM
hai

i want to know that how to maximize the browser window of an asp.net application

when we browse through the network browser,the window state will be at
maximised state but when i run an ASP.net application it won't run as such.

plz help,
thanks in advance.
Report
Re: how to maximize the browser window of an asp.net application Posted by iwilld0it on 12 Oct 2004 at 9:49 AM
: hai
:
: i want to know that how to maximize the browser window of an asp.net application
:
: when we browse through the network browser,the window state will be at
: maximised state but when i run an ASP.net application it won't run as such.
:
: plz help,
: thanks in advance.
:

You'll have to use JavaScript to simulate that. Look into the Window.Open() function on the internet. To mess with the actual behavior of the browser is impossible, as far as I know. You might be able to accomplish it with a DHTML behavior, but that is Internet Explorer specific.
Report
Re: how to maximize the browser window of an asp.net application Posted by mangesh004 on 13 Oct 2004 at 12:44 AM
Hi friend
there is no way through which you can maximize the browser window but there is one mid way through which browser will fit in the whole screen.
but that even possible only through Java script, it can be done as follows

<script language="JavaScript">
top.window.moveTo(0,0);
if (document.all) {
top.window.resizeTo(screen.availWidth,screen.availHeight);
}
else if (document.layers||document.getElementById) {
if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth){
top.window.outerHeight = screen.availHeight;
top.window.outerWidth = screen.availWidth;
}
}
</script>

Put this code in the HTML view of your page or the code behind.
If you have any problem implementing it into code behind plz feel free to ask.

Thanking you,
Mangesh
Report
Re: how to maximize the browser window of an asp.net application Posted by v_j_latha on 21 Oct 2004 at 6:14 AM
: Hi friend
: there is no way through which you can maximize the browser window but there is one mid way through which browser will fit in the whole screen.
: but that even possible only through Java script, it can be done as follows
:
: <script language="JavaScript">
: top.window.moveTo(0,0);
: if (document.all) {
: top.window.resizeTo(screen.availWidth,screen.availHeight);
: }
: else if (document.layers||document.getElementById) {
: if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth){
: top.window.outerHeight = screen.availHeight;
: top.window.outerWidth = screen.availWidth;
: }
: }
: </script>
:
: Put this code in the HTML view of your page or the code behind.
: If you have any problem implementing it into code behind plz feel free to ask.
:
: Thanking you,
: Mangesh
:
thanks for the help
but i don't scriting
iam learning asp.net .will u able to provide the same code in Visual Basic ?

tks again
have a nice day


Report
Re: how to maximize the browser window of an asp.net application Posted by iwilld0it on 21 Oct 2004 at 11:07 AM
: : Hi friend
: : there is no way through which you can maximize the browser window but there is one mid way through which browser will fit in the whole screen.
: : but that even possible only through Java script, it can be done as follows
: :
: : <script language="JavaScript">
: : top.window.moveTo(0,0);
: : if (document.all) {
: : top.window.resizeTo(screen.availWidth,screen.availHeight);
: : }
: : else if (document.layers||document.getElementById) {
: : if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth){
: : top.window.outerHeight = screen.availHeight;
: : top.window.outerWidth = screen.availWidth;
: : }
: : }
: : </script>
: :
: : Put this code in the HTML view of your page or the code behind.
: : If you have any problem implementing it into code behind plz feel free to ask.
: :
: : Thanking you,
: : Mangesh
: :
: thanks for the help
: but i don't scriting
: iam learning asp.net .will u able to provide the same code in Visual Basic ?
:
: tks again
: have a nice day
:
:
:

There is no visual basic equivalent ... you have to use that JavaScript in order to get the functionality you want. It is an unfortunate side-effect of ASP.NET being server-side.



Report
Re: how to maximize the browser window of an asp.net application Posted by kernelv12 on 30 Oct 2004 at 4:26 AM
Hi,
: There is no visual basic equivalent ... you have to use that JavaScript in order to get the functionality you want. It is an unfortunate side-effect of ASP.NET being server-side.

True so...but you can use RegisterClientScriptBlock if you're not familiar with HTML, and you don't want to mess around with your app's html source. You could try the following (for ex. in the Page_Load section of you VB code):

RegisterClientScriptBlock("", "<script>top.window.moveTo(0,0); top.window.resizeTo(screen.availWidth,screen.availHeight);</script>")


Report
Re: how to maximize the browser window of an asp.net application Posted by v_j_latha on 4 Nov 2004 at 3:57 AM
: Hi,
: : There is no visual basic equivalent ... you have to use that JavaScript in order to get the functionality you want. It is an unfortunate side-effect of ASP.NET being server-side.
:
: True so...but you can use RegisterClientScriptBlock if you're not familiar with HTML, and you don't want to mess around with your app's html source. You could try the following (for ex. in the Page_Load section of you VB code):
:
: RegisterClientScriptBlock("", "<script>top.window.moveTo(0,0); top.window.resizeTo(screen.availWidth,screen.availHeight);</script>")
:
:
:
hai friend
tnk u very very much
i worked
i wrote it in page_init event so the code executes before the page executes

i was very upset regarding this prb
tnk u once again
it really helped me

bye
have a nice day

Report
Re: how to maximize the browser window of an asp.net application Posted by PKSpence on 14 Dec 2011 at 9:56 AM
Outstanding, m8! Exactly what I was looking for!
Report
Re: how to maximize the browser window of an asp.net application Posted by PKSpence on 14 Dec 2011 at 9:58 AM
Outstanding, m8! Exactly what I was looking for!



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.