0 Replies Latest reply on Mar 25, 2008 2:46 PM by KomputerMan.com

    Closing a window after an Excel dump

    KomputerMan.com Level 1
      I am using a call to a cfm page from my Flex app to generate an Excel dump for my end users. The code I use in the Flex app is as follows:

      var url:URLRequest = new URLRequest("/Irec_Flex/Reports/EOHist_Excel.cfm");
      url.data = uv;

      The template EO_Hist_Excel.cfm just generates an Excel dump using CFHEADER and CFCONTENT. All of that works great. The only problem with this is that after the Excel file is generated I am left with a popup window that has the message "Action Canceled" in it. I have been searching all over the place looking at how I can close this window after the Excel file is generated. As I understand it JavaScript is useless after the CFHEADER tag is used. I finally came across this post where somebody solved the same problem... unfortunately the details were missing so if somebody could help me out a bit here I would be grateful for ever... O.K. maybe not for ever but I will revere you as a CF-Flex GURU for at least a half of an hour!!!

      Here is the post I found that is missing the specifics...
      I did solve the problem. I noticed that the Flex generated html code was
      using a zero height IFRAME to hold the history data. I just added another
      named IFRAME and pointed the loadvars.send at it. Works great!

      I really don't see how this message will help me close a popup window after the Excel file has been created... Does anybody out there understand this???

      Thanks in advance for the help!!!

      Have an Ordinary Day...
      KomputerMan ~|:-)