I use Flex in Flash Player 10 on Windows, using FileReference to load a file into memory, as shown below.
My problem is that when the file is locked by Windows, my FileReference does not give me any feedback that the file is unavailable - it just never sends any events after my load() call.
Does anyone know how to report that Flash Player cannot open the file?
var fileReference:FileReference = new FileReference(); private function onClick():void { fileReference = new FileReference(); fileReference.addEventListener(Event.SELECT, onSelect); fileReference.addEventListener(Event.COMPLETE, onComplete); fileReference.addEventListener(Event.CANCEL, onOther); fileReference.addEventListener(IOErrorEvent.IO_ERROR, onOther); fileReference.addEventListener(ProgressEvent.PROGRESS, onOther); fileReference.addEventListener(SecurityErrorEvent.SECURITY_ERROR, onOther);
flex windows flash actionscript-3 filereference
Michael Brewer-Davis
source share