Oncomplete (Filereference.oncomplete Event Listener); Onhttperror (Filereference.onhttperror Event Listener) - MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference

Actionscript 2.0 language reference
Table of Contents

Advertisement

onComplete (FileReference.onComplete event
listener)
onComplete = function(fileRef:FileReference) {}
Invoked when the upload or download operation has successfully completed. Successful
completion means that the entire file has been uploaded or downloaded.
Availability: ActionScript 1.0; Flash Player 8
Parameters
fileRef:flash.net.FileReference
Example
The following example traces out a message when the
import flash.net.FileReference;
var listener:Object = new Object();
listener.onComplete = function(file:FileReference):Void {
trace("onComplete: " + file.name);
}
var fileRef:FileReference = new FileReference();
fileRef.addListener(listener);
var url:String = "http://www.macromedia.com/platform/whitepapers/
platform_overview.pdf";
fileRef.download(url, "FlashPlatform.pdf");
onHTTPError (FileReference.onHTTPError event
listener)
onHTTPError = function(fileRef:FileReference, httpError:Number) {}
Invoked when an upload fails because of an HTTP error.
Because of the way that Flash Player relies on the browser stack during file download, this
error is not applicable for download failures. If a download fails because of an HTTP error,
the error is reported as an I/O error.
Availability: ActionScript 1.0; Flash Player 8
- The FileReference object that initiated the operation.
onComplete
FileReference (flash.net.FileReference)
event is triggered.
571

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash 8

Table of Contents

Save PDF