ModalWindow not firing Page_Load.. please help

Discussion in 'ASP .Net' started by Shady Azzam, Jul 5, 2005.

  1. Shady Azzam

    Shady Azzam Guest

    I have an aspx page that calls a modal dialog which loads another aspx page,
    using javascript:
    self.showModalDialog(\\target.aspx);

    The first time i open the modal dialog, target.aspx's Page_Load runs fine.
    But if I close the window and try and reopen it, the Page_Load is not
    called, and a cached version
    of the page is displayed. Only after i've closed and reopened the browser,
    browsed to the original page and called the modal window does target.aspx's
    Page_Load run again.

    Why is this happening and what can i do to ensure Page_Load is always fired?

    Any help is very appreciated,
    Shady
     
    Shady Azzam, Jul 5, 2005
    #1
    1. Advertisements

  2. This is not a permanent solution because it involves client change, but have
    you tried opening IE Tools -> Internet Options -> Settings and selecting
    "Every visit to the page" and see if the problem repros.

    --
    - Shuvro
    SDE, MSFT

    This posting is provided "AS IS" with no warranties, and confers no rights.
    Use of included script samples are subject to the terms specified at
    http://www.microsoft.com/info/cpyright.htm.
     
    Shuvro Mazumder [MSFT], Jul 5, 2005
    #2
    1. Advertisements

  3. Shady Azzam

    Wade Guest

    I actually prefer to turn page output caching off in the ASPX page ...
    something like this:

    <%@ OutputCache Duration="1" VaryByParam="*"%>

    Not sure if this is the very best way to do it, but it seems to work well --
    better than telling 100's of users to change their Internet Options.

    Wade
     
    Wade, Jul 5, 2005
    #3
    1. Advertisements

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.