[urgent] Flex fileRef.download problems.

Hi all,
I am having trouble figuring out what to do here.
I am sending images to coldfusion, and using cfzip to create a zip of the images for download.
I am using fileRef.download to download the zip to the user's computer in actionscript.
The problem is that flex will let the user download the zip before it is finished compiling.
So if there are 68 images in the zip on the webserver, depending on how fast you select the save location you could only get 42...or 29....etc.
I tried putting the download function in the return handler for the coldfusion remote object, but fileRef.download must be executed by a mouse-click for security reasons.
Here is the click handler for the "download images" button.
Here is the code below:
public function clickHandler1(event:Event):void
                h = 0;
                randomFileNum = Math.round(Math.random()*(99999-11111))+11111;
                var t:int;
                for (t = 0; t < HiResImageCollection.length; t++)
                image1 = HiResImageCollection[h];
                imgStyleNumber = StyleNumberCollection[h]+ "_" + ColorCollection[h] + pORiCollection[h] ;
                cfcquer4.getCartImages(image1,imgStyleNumber,randomFileNum);
                h = h + 1;
                 downloadURL.url = "http://costmesa-svr-17/HIB/ImagesTemp/DownloadedImages" + randomFileNum + ".zip" + "?" + Math.random();
                 fileRef.download(downloadURL, 'DownloadedImages' + randomFileNum + '.zip');
Thank you for your much needed help.
JK

My server-side knowledge is limited, however have you looked into Flex's AsyncToken? Also this article has info at it:
An AsyncToken Primer
It seems that using Async may be more ideal, then say, to have a timer that will execute your  fileRef.download() a few seconds later.  But then again, I am weak on this side of the field.

Similar Messages

  • Basic flex builder download problem

    I downloaded and used flex builder standalone trial version 3 days ago, before removing it to install flex builder eclipse plugin which is what I should have downloaded initially.
    Now I keep getting a cryptic message ['an error has occurred'] when trying to download the plugin version. I know other people who are not having this problem. Is it caused by the fact that builder was already installed?
    What is the quickest way of sorting it out from the UK?
    Thanks

    So it sounds like you had to create an Adobe account first.
    Try going to the download page directly now
    http://www.adobe.com/cfusion/entitlement/index.cfm?e=flex3email

  • IPhone app store downloading problem

    I have iPhone app store downloading problem (iOS 5). I could not download or update any software successfully from yesterday. Every app shows "waiting for download" but nothing happen for two days. It seems my app store does not connect to server. I use same account in my iPad, but it works normal. So, what happen to my iPhone? Please help me!

    Hold the home button and lock button for 10 seconds to reboot the iPhone.

  • Adobe reader download problem on mac.  when i try to download reader it says i need adobe air.  when i try to download adobe air it says it's no longer available or supported.  i deleted the old air because i got a message saying i needed to delete it.

    adobe reader download problem on mac.  when i try to download reader it says i need adobe air.  when i try to download adobe air it says it's no longer available or supported.  i deleted the old air because i got a message saying i needed to delete it. what should i do?  my operating system is Mac 10.7.5

    You don't need Adobe AIR to download or install Adobe Reader.
    Try downloading the offline installer from http://get.adobe.com/reader/enterprise/

  • Rental movie download problems

    I
    I trie to download a movie ,it says it has downloaded buy won't let me play it

    I have been having downloading problems for the last few days and despite all the tricky advice. iTunes jut can't solve the problem.
    These are some of the actions taken:-
    Uninstall and reinstall iTunes
    Turn off Anti Virus (didn't like that one!) Then uninstall anti virus!!!!!! No!!!
    Change preferences in iTunes
    Update iTunes...etc etc etc etc etc!  ZIP!
    Think I will go back to Big Pond Movies as is a lot easier and less stressful.
    Do I Tunes think everyone has telescopic eyesight? The text is so small (just like all their printed matter) have to use a magnifying glass.
    As you can detect, I am less than happy.
    Graham

  • ** 6i Download problems - Product Management speaks **

    Firstly on behalf of the 6i Product Management team let me appologise for the problems you have been experiencing with Technet and specifically with downloading 6i.
    I watch this forum and answer questions time permitting whenever I can, this forum (along with comp.databases.oracle.tools and ODTUG) are monitored by Product Management.
    You need to understand that Oracle is a very big company and that getting all the little parts to work seamlessly together sometimes doesn't work as well as it should, so please be assured that Tools PM is working as hard and as fast as it can to ensure that 6i is available for you to download.
    I have made enquiries today to find out what is happening at Technet. This is a division of Marketing based out of the US HQ, the PM teams have no responsibility for the management or maintenance of this site, we merely monitor mail lists and post our new software when complete.
    I am waiting for information on the action plan to resolve the performance and download problems being experienced by the Developer community.
    In response to some of the comments posted about downloading
    It is obvious that 6i has been out for a WHILEActually this is not true, it has been available for download for a while, but not orderable..
    Product Release Point Dates:
    (1)
    Release to MFG - 24-MAR-00 (This date is used by engineering and is the start of the 16-week period for the 1st patchset.) THE PRODUCT IS NOT ORDERABLE YET.
    (2)
    Release to PRG - 14-APR-00 (This is the M&D hand-off date for the Tools CD Pack.) THE PRODUCT IS NOT ORDERABLE YET.
    (3)
    Between 6:00PM PST and midnight 27-APR-00 - R6i, Windows, was added to the Oracle Store and officially orderable.
    I have seen many posted messages, iTARS, etc referencing the availability of downloading forms updates, availablity of getting patchesAs you will see from the information above, this is not possible, patch one for 6i will not be released until 16 weeks after 24-MAR-2000
    How much do we have to pay and who do we have to kiss to get a freakin update from Oracle? As the author of this comment has a support contract, they will know that you do not automatically get updates for products for which you hold licences. You merely need to order the latest version of the CD. Your support Account Manager will be able to advise you how to do this.
    Once again, please be assured that we value your time, effort and feedback and that we do watch this forum with great interest.
    I hope you found this information useful.
    Jason Pepper
    Senior Product Manager
    Oracle Enterprise Internet Tools

    As an update on the OTN performance problem I talked about earlier, I got some info from Global Ops
    Customers are trying to download software from ftp.oracle.com, a server managed by the datacenter. The server is actually 2 servers (mirrored), with 1,400 connections (700 per machine). Bottom line is that ftp.oracle.com doesn't have enough connections to support the number of users trying to download Oracle products each day. Approval has been received for a dedicated OC3 pipe to the ftp server; it's believed this will boost the current capacity to 4-5 times what's there today.
    Other improvement measures are being investigated.
    Whilst this is being resolved, please consider ordering the CD which is free. I have just tested this and it worked for me ;)
    Jason Pepper
    Oracle Enterprise Internet Tools

  • EWA Alert 'rating not defined' and 'download problem' (last week it's fine)

    Hi Friends,
    Please help me with this Alert.
    We have a weekly schedule of EWA report. Lat week the report was fine (green).
    This week it's been grayed out. the erro is Rating not defined and download problem.
    I have run the EWA report and it generated well.
    As per the EWA aler recomendation, i have run the sysprep check (sdcc) in target system. as per the report ihave checked the patches, they seems to be ok.However till last week the report was fine(Green).
    I have checked the RFC connections etc.
    Please check the following error message and help me soon. Since this is a production system.
    Regards
    srini

    hi srini,
    r there any upgrades of patches as now i am experiencing the same problem to my qty and dev servers where i have scheduled ewa reps.
    it says dwnld problem... but i assume the recent cvhanges to our servers patch levels has some thing to do with this..as that is the only changewe had perfromed...i would keep u informed once i check back to this issue.
    let me know if u find any,
    Br,
    Sri
    Award points for helpful answwers

  • How to download garageband old version? i mean version 1.0 to install it on iphone 4s with ios 6.0.1??? please help urgently, how to download garageband old version? i mean version 1.0 to install it on iphone 4s with ios 6.0.1??? please help urgently

    how to download garageband old version? i mean version 1.0 to install it on iphone 4s with ios 6.0.1??? please help urgently, how to download garageband old version? i mean version 1.0 to install it on iphone 4s with ios 6.0.1??? please help urgently

    I did this a few weeks ago to be sure it was going to work for a young person I was giving my ipod to.  Then I reset the information for her and now it will not load.  Very sad.  She is so talented and she really needs this.   Anyone know?

  • Need flex 3 download trail version

    Need to create a new component in xcelsius,for which I need a flex 3 download, but before purchasing the flex 3,I want to try it with a trial version. I could not get my property sheet to work with flex 2 hot fix 3

    Direct Download Links for Adobe Software
    Though that would be slightly futile - you cannot buy those old versions anymore, anyway, so you might just as well move on to FlashBuilder 4.6 directly.
    Mylenium

  • Downloading problem with AS2

    Hi all,
    I have an issue which has been driving me mad all morning. I'm trying to download a file from a remote server. I use the following code:
    import flash.net.FileReference;
    var listener:Object = new Object();
    var fileRef:FileReference = new FileReference();
    fileRef.addListener(listener);
    var url:String = "http://www.mysite.com/myFolder/myFile.jpg";
    if(!fileRef.download(url)) trace("dialog box failed to open.");
    If I execute this code, it works just fine. If I insert this code inside a sendAndLoad, it stops working. Here's an example:
    import flash.net.FileReference;
    c = new LoadVars();
    r = new LoadVars();
    r.onLoad = function(ok)
         var listener:Object = new Object();
         var fileRef:FileReference = new FileReference();
         fileRef.addListener(listener);
         var url:String = "http://www.mysite.com/myFolder/myFile.jpg";
         if(!fileRef.download(url)) trace("dialog box failed to open.");
    c.a = 1;
    c.sendAndLoad("http://www.mysite.com/myPhp.php", r, "POST");
    Does anyone have any idea as to why it doesn't work?
    Thank you!!!

    Hi, I'm back again.
    I've tried every possible combination, but I get the same results. Here's the code:
    import mx.controls.Alert;
    import flash.net.FileReference;
    System.security.allowDomain("www.mysite.com");
    // FIRST TRY  <------- GETS EXECUTED IF I RUN THE SWF, NOT IF I RUN THE HTML
    var listener:Object = new Object();
    listener.onSelect = function(file:FileReference):Void { trace("onSelect: " + file.name); }
    listener.onCancel = function(file:FileReference):Void { trace("onCancel"); }
    listener.onOpen = function(file:FileReference):Void { trace("onOpen: " + file.name); }
    listener.onProgress = function(file:FileReference, bytesLoaded:Number, bytesTotal:Number):Void { trace("onProgress with bytesLoaded: " + bytesLoaded + " bytesTotal: " + bytesTotal); }
    listener.onComplete = function(file:FileReference):Void { trace("onComplete: " + file.name); }
    listener.onIOError = function(file:FileReference):Void { trace("onIOError: " + file.name); }
    var downloadItem:FileReference = new FileReference();
    downloadItem.addListener(listener);
    if(!downloadItem.download("http://www.adobe.com/platform/whitepapers/platform_overview.pdf")) { trace("dialog box 1 failed to open."); }  
        c = new LoadVars();
        r = new XML();
        r.ignoreWhite = true;
        r.onLoad = function (ok)
            delete this.onLoad;
            var nodes = this.firstChild.childNodes;
           trace(nodes[1].firstChild.nodeValue);    <-------- GETS EXECUTED IF I RUN THE HTML, NOT IF I RUN THE SWF
    // SECOND TRY  <------ NEVER GETS EXECUTED
    var listener:Object = new Object();
    listener.onSelect = function(file:FileReference):Void { trace("onSelect:  " + file.name); }
    listener.onCancel = function(file:FileReference):Void {  trace("onCancel"); }
    listener.onOpen = function(file:FileReference):Void { trace("onOpen: " +  file.name); }
    listener.onProgress = function(file:FileReference, bytesLoaded:Number,  bytesTotal:Number):Void { trace("onProgress with bytesLoaded: " +  bytesLoaded + " bytesTotal: " + bytesTotal); }
    listener.onComplete = function(file:FileReference):Void {  trace("onComplete: " + file.name); }
    listener.onIOError = function(file:FileReference):Void {  trace("onIOError: " + file.name); }
    var downloadItem:FileReference = new FileReference();
    downloadItem.addListener(listener);
    if(!downloadItem.download("http://www.adobe.com/platform/whitepapers/platform_overview.pdf"))  { trace("dialog box 2 failed to open."); }
    c.a = 1;
    c.sendAndLoad("http://www.mysite.com/myphp.php", r, "POST");
    Here's the deal:
    1) I execute the SWF alone ---> the saveFile dialog appears. No trace messages appear. The 'download' that's getting executed is the one labeled FIRST TRY.
    2) I execute the HTML ---> No saveFile dialog appears, but I get 2 trace messages telling me that dialog boxes 1 and 2 have failed to open and I get the trace containing the value returned by the PHP
    I've tried this from two different computers, one at home, the other at the office and get the same results. What am I doing wrong??? I appreciate all your help.

  • Download Problems with K8N Neo4 Platinum Nvidia Ethernet Controller

    Just to ask if there is some basic setup for Nvidia network drivers in Windows or in BIOS since I'm having download errors with a DSL connection when i use the Nvidia networking controller, not depending from  the OS I'm booting (WinXP Pro SP2 or  WinXP pro 64). When I download using the Marvell Yukon controller everything  works fine in both operating systems. Additional specs:
    K8N Neo 4 Platinum (latest MSI Nforce4 drivers)
    Athlon 64 X2 4200+
    2GB Transcend RAM
    EVGA 6600 GT 128MB PCI-E
    Samsung Spinpoint 200GB SATA (Win XP Pro + SP2)
    Samsung Spinpoint 200GB SATA (Win XP Pro 64)
    Samsung TS-H522U DVD-RW
    Seventeam ST-550EAG  3.3@30A  5.0@30A  12V1 & 12V2 @ 18A each

    Quote from: Indigian on 07-November-05, 00:23:35
    Open up the nvidia firewall.
    Click on 'Active Armour'
    Click on 'Application'
    change the setting from 'offloadable' to 'notoffloadable'
    This solves the download problem.
    Indigian,  you are The Man!!!!!
    That solved it !!! Thank you very much!

  • Download problems with Oracle 9i

    So that we may better diagnose DOWNLOAD problems, please provide the following information.
    - Server name : http://download-east.oracle.com
    - Filename : 92010NT_Disk1.zip, 92010NT_Disk2.zip, 92010NT_Disk3.zip
    - Date/Time : 15 Aug 2002
    - Browser + Version : IE 5.x, Netscape 4
    - O/S + Version : MS Windows 98/2000
    - Error Msg
    I have been trying to download Oracle 9i for the past three weeks. Every time I try to download the above mentioned files the file Login.jsp gets copied. I've tried using both GetRight and GoZilla!
    Could someone please advise me what to do. Any help would be appreciated.

    I recently downloaded Oracle9i personal edition, it took me more than 7 hours, and the downloaded zip file is A91514-01.zip. You need to check how reliable is your internet connection. regards. winston

  • Need help: Flex  record webcam problem, how to setting Brightness,Contrast,Saturation and Sharpness

    Hello, dear all
    Please help me!
    Flex  record webcam problem, how to setting Brightness,Contrast,Saturation and Sharpness?
    nsOutGoing=new NetStream(nc);
    nsOutGoing.attachCamera(m_camera);
    nsOutGoing.publish(filename, "record");
    I want to control the Brightness,Contrast,Saturation and Sharpness for the recorded flv file.
    At present, I only can control the videodisplay object, but I can not able to control Camera.
    Thanks very much!!
    kimi
    MSN: [email protected]

    Can I change a Video object to to Camera object, If yes, How do??
    nsOutGoing.attachCamera(video as Camera);// it does not work rightly
    thanks

  • Firefox downloads "failed". Have reset FF, been through "downloading problems" trouble doc, and uninstalled/reinstalled FF w/o luck. Safari is able to download.

    Recently I am unable to download anything in FF. It briefly acts as if downloading, but the file is corrupted and the next to the file in the DL manager it just says "Failed".
    I tried Resetting FF. No luck.
    Then I tried all the steps in the "downloading problems" support doc. No luck.
    I tried with all add-ons disabled. No luck.
    In desperation, I searched for "Firefox" and moved two folders called Firefox, the application, and a .plist file to the trash (still there) and redownloaded Firefox and reinstalled. No luck.
    If I click on a .pdf it will be be viewable, but it won't download. It's not just .pdfs that fail, it is any file I try and download.

    I have the same problem and I also tried a lot of troubleshooting advices without any success.
    The problem seems to be with OS X Parental Control turned on and using a other account than the one of the admin.
    The user sl-nw found a short-term solutions (changing back to version 31, working like a charm or turning off Parental Control), yet a long-term solution is needed:
    https://support.mozilla.org/en-US/questions/1018279
    Perhaps Firefox should add a bug fix to their next update.

  • JDeveloper 3.0 Download Problem

    I'm unable to download the first file segment of JDeveloper 3.0
    Netscape tells me "... is unable to find the file or directory
    named /pub/www/otn/jdeveloper/jdev30split/jdev.30a.exe". It
    looks like there's an extra dot in the file name. FYI: I've
    been able to download all the other file segments. Thanks!
    null

    The download problem with the first file has been fixed on OTN.
    Laura
    Jim Tabbut (guest) wrote:
    : adrian martin (guest) wrote:
    : : Jim Tabbut (guest) wrote:
    : : : I'm unable to download the first file segment of JDeveloper
    : 3.0
    : : : Netscape tells me "... is unable to find the file or
    : directory
    : : : named /pub/www/otn/jdeveloper/jdev30split/jdev.30a.exe".
    It
    : : : looks like there's an extra dot in the file name. FYI:
    I've
    : : : been able to download all the other file segments. Thanks!
    : : Jim,
    : : I suggest you ftp to the site ftp.oracle.com. Navigate to
    : : pub/www/otn/jdeveloper/jdev30split/
    : : There you will see all the downloadable exe files. Pick the
    : : first one (jdev30a.exe) and download it.
    : : The download time is very slow - not sure why - could be my
    : LAN.
    : : Regards,
    : : Adrian
    : Got it, thanks!
    null

Maybe you are looking for

  • Problem with CUPS and Canceling jobs

    I am using OS 10.3.9 on a 1.42 MDD PowerMac I am having a problem trying to cancel Jobs using the CUPS interface. When I select "Cancel" I get an error "client-error-forbidden". I have tried logging in as Root but the same error occurs. I have run "C

  • My display shows up in green when usually white

    My display shows up in an aqua instead of white and I have not changed any display settings.

  • Clearing for customers

    Hi we are working on automatic customer clearance but facing some difficulties. In OB74 what criteria i should define for clearing customers automatically. I have tried using Assignment number but that doesnot work for me. please guide.

  • Error: Got minus one from a read call, sporadic disconnections...

    Hello, I am running JSP apps on Tomcat hitting against Oracle 10g DB. They have been working great. However, recently I am experience some bazzare events. Sporadically, webpages are only displaying partial result or even nothing from DB calls. When I

  • I still use an XP. I cannot download a Windows 7 Firefox browser if I don't have Windows 7, right?

    I am irritated. Your browser is insisting that I update to the newer version, yet I don't have Windows 7. I cannot afford to upgrade to W-7 and I've been told by W-7 that I cannot upgrade my XP OS to Windows 7. So what's a girl to do? How can I bypas