Refresh main browser window when secondary window is closed.

Discussion in 'ASP .Net' started by =?Utf-8?B?R2FyeQ==?=, Nov 11, 2005.

  1. Is it possible to refresh a browser window when a secondary browser window
    has been closed?

    For example, I have a main web form that functions purely as a datagrid,
    when a user clicks on a record in the datagrid a new window is opened (using
    the javascript window.open function), from this window the user can update or
    delete the record and then close the window once he/she is finished.
    Obviously when the record is deleted it will still appear in the data grid in
    the main form because the data has not been reloaded, however I would like to
    force a reload of the data when the focus has returned back to the main form
    containing the datagrid.

    Does anyone know of a way to achieve this?
    =?Utf-8?B?R2FyeQ==?=, Nov 11, 2005
    #1
    1. Advertising

  2. In case anyone else has the same question I found that if you create a close
    button as follows....

    <INPUT id="ButtonClose"
    onclick="window.opener.document.forms[0].submit();window.close()"
    type="button" value="Close" name="ButtonClose">

    the parent window will then refresh whin the child window is closed.
    =?Utf-8?B?R2FyeQ==?=, Nov 11, 2005
    #2
    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. Morten Wennevik
    Replies:
    3
    Views:
    383
    =?Utf-8?B?U3JlZWppdGggUmFt?=
    Nov 2, 2005
  2. Replies:
    0
    Views:
    308
  3. Matt Kruse
    Replies:
    5
    Views:
    293
    Richard Cornford
    Sep 9, 2003
  4. Charles Packer

    Secondary window won't resize

    Charles Packer, Dec 26, 2003, in forum: Javascript
    Replies:
    2
    Views:
    103
    Charles Packer
    Dec 28, 2003
  5. TM360
    Replies:
    2
    Views:
    185
    TM360
    Jun 30, 2005
Loading...

Share This Page