Solved

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

Posted on 2006-07-05
2
213 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

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I know the transition can be hard. We got used to the ease of use ActionScript 2 had, but honestly, it became problematic later on, especially if designers were involved in the project and found it easy to add code as they saw fit. So, this artic…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
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…
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.

785 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