Opening a new browser window to a specific size without the menu bar and address window.

Discussion in 'ASP .Net' started by UJ, Jun 27, 2005.

  1. UJ

    UJ Guest

    How can I open a window, preferably through a hyperlink, that will open a
    new window with no menu bar/address bar and is a specific size?

    TIA - Jeffrey.
     
    UJ, Jun 27, 2005
    #1
    1. Advertising

  2. UJ

    Curt_C [MVP] Guest

    Re: Opening a new browser window to a specific size without the menubar and address window.

    UJ wrote:
    > How can I open a window, preferably through a hyperlink, that will open a
    > new window with no menu bar/address bar and is a specific size?
    >
    > TIA - Jeffrey.
    >
    >

    Its clientside code...
    Look at the window.open() call from javascript. It will allow you to do
    what you requested.

    --
    Curt Christianson
    site: http://www.darkfalz.com
    blog: http://blog.darkfalz.com
     
    Curt_C [MVP], Jun 27, 2005
    #2
    1. Advertising

  3. theres a little example to help you along, just needs the extra options
    adding

    --
    Regards

    John Timney
    ASP.NET MVP
    Microsoft Regional Director

    <html>
    <head>
    <script language="VB" runat="server">

    Sub Page_Load( sender as Object,e as EventArgs)

    'Form the script that is to be registered at client side.
    Dim scriptString as String = "<script language=JavaScript> function
    DoClick() {"
    ScriptString +=
    "window.open('http://www.mvps.org','MyWindow','width=500,height=500');}<"
    scriptString += "/"
    scriptString += "script>"

    If(Not IsClientScriptBlockRegistered("clientScript"))
    RegisterClientScriptBlock("clientScript", scriptString)
    End If
    End Sub
    </script>
    </head>
    <body topmargin="20" leftmargin="10">
    <form id="myForm" runat="server">

    <INPUT id="launchButton" onclick="DoClick();" type="button"
    value="Submit" name="myButton" runat="server">


    </form>
    </body>
    </html>



    "Curt_C [MVP]" <software_at_darkfalz.com> wrote in message
    news:...
    > UJ wrote:
    >> How can I open a window, preferably through a hyperlink, that will open a
    >> new window with no menu bar/address bar and is a specific size?
    >>
    >> TIA - Jeffrey.

    > Its clientside code...
    > Look at the window.open() call from javascript. It will allow you to do
    > what you requested.
    >
    > --
    > Curt Christianson
    > site: http://www.darkfalz.com
    > blog: http://blog.darkfalz.com
     
    John Timney \(ASP.NET MVP\), Jun 27, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Matt
    Replies:
    0
    Views:
    3,594
  2. John Hann
    Replies:
    0
    Views:
    6,159
    John Hann
    Aug 21, 2004
  3. Matt
    Replies:
    9
    Views:
    71,227
  4. Matt
    Replies:
    9
    Views:
    613
    kaeli
    Aug 23, 2004
  5. Tim
    Replies:
    1
    Views:
    333
    Grant Wagner
    Jan 18, 2005
Loading...

Share This Page