refreshing parent window after download completes

Posted on 2011-04-29
Last Modified: 2012-05-11
I have a link in a page to download a file and on completion of the download i want to refresh the parent page.I would like to know the code to achive this  
Question by:czutshi
    LVL 23

    Accepted Solution

    There is no direct solution for this because download works in a separate request.

    But there is a work around.

    If you have tracking session for the users, then you can do the following.

    When user clicks on some download link, it will start as a new request.
    Server needs to keep track of this download request.
    In the server, once the download is complete, you need to update a variable in session saying when the download was complete.

    Client periodically, should send a ajax request to server asking if the file download is completed. If completed, then just refresh the page normally.

    Without session tracking is also possible, but you need some kind of intelligence to identify that ajax and download requests are coming from same browser instance.


    Author Closing Comment

    Solution seems to give a headway but is not fully implemented yet

    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Join & Write a Comment

    As with any other System Center product, the installation for the Authoring Tool can be quite a pain sometimes. This article serves to help you avoid making these mistakes and hopefully save you a ton of time on troubleshooting :)  Step 1: Make sur…
    This is an issue that we can get adding / removing permissions in the vCSA 6.0. We can also have issues searching for users / groups in the AD (using your identify sources). This is how one of the ways to handle this issues and fix it.
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now