Solved

URGENT : The class 'flash.net.FileReference' could not be loaded.

Posted on 2006-07-05
2
199 Views
Last Modified: 2012-06-21
we are using Flash MX PRO 2004 to do a file upload to a PHP page

we are recieving the following error in the activescript

**Error** Scene=Scene 1, layer=Layer 1, frame=1:Line 27: The class 'flash.net.FileReference' could not be loaded.
     listener.onOpen = function(selectedFile:FileReference):Void {

have we missed something or do we need to import the class into FlashMX project?


This is our code snippet for the actionscript

import flash.net.FileReference;
var listener:Object = new Object();
listener.onSelect = function(selectedFile:FileReference):Void {
statusArea.text += "Attempting to upload " + selectedFile.name + "\n";
selectedFile.upload("http://www.helpexamples.com/flash/file_io/uploadFile.php");
};
0
Comment
Question by:Robinsonx6
2 Comments
 
LVL 34

Accepted Solution

by:
Aneesh Chopra earned 500 total points
ID: 17042412
Hi,

'flash.net.FileReference'  comes with Flash 8 not with Flash MX pro 2004
You need Flash 8 to compile ur code..

Rgds
Aneesh
0
 
LVL 2

Author Comment

by:Robinsonx6
ID: 17043813
thanks for the answer
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
shockwave problems 3 216
free flash maker 5 197
Web browser crash when play videos 24 208
HTML 5 video and audio or Flash 1 31
This is a very simple example to help those of you who are still migrating from AS2 to AS3 understand the redesigned event model in AS3. In AS2.0, event functions (that is, the function to be performed when an event is fired) were stored as a pro…
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now