Thursday, October 5, 2023
rated 0 times [  0] [ 4]  / answers: 1 / hits: 38386  / 15 Years ago, fri, march 20, 2009, 12:00:00

I have a web page (made with JSF) where some links allow the user to get a PDF file.

When the user clicks on such a link, a waiting popup (it is a modal panel) is displayed (because the generation of the PDF can be long), and once the file is created, IE displays the File download popup that proposes Open, Save and Cancel options.

Is there a way in Javascript to know from my web page when this popup is closed, i.e. when the user has saved (or opened) the PDF file?

To be a little more precise, in the web page that displays the link to the PDF file, a modal popup is displayed (the waiting popup) in order to make the user waits for the File download popup. The problem is that when the user Saves (or open) the PDF file, the File download popup closes, but the user then returns to the original webpage, with the waiting popup still displayed.

Note that my application runs only in IE6, so I am not against a IE(6)-only solution...

I have also no problem with solutions that need jQuery ;)

If a solution exists to catch any event that is fired exactly when the File download popup is displayed to the user (i.e. before the user chooses to Save, Open or Cancel), it will be fine for me too!

More From » internet-explorer


I had to work on this kind of issue, on another project. I finally found a smart solution, as explained in another Stackoverflow question.

The explanation is given in the following post:

The idea is to simply use a cookie to define when the file is downloaded.

[#99818] Saturday, March 14, 2009, 15 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.

Total Points: 742
Total Questions: 94
Total Answers: 97

Location: Iraq
Member since Fri, Jun 5, 2020
3 Years ago
anjelicadixied questions