i’m doing a flash web site and i want to import a html file to the flash file
this is the code which i found on the Ehow
here is the tutorail
var displayText:TextField = new TextField();
displayText.scaleY = stage.stageHeight/600;
displayText.scaleX = stage.stageWidth/1225;
displayText.width = 400;
displayText.height = 700;
var importFile:URLLoader = new URLLoader();
var requestedFile: URLRequest = new URLRequest("HTML/الدرس الأول.htm");
importFile.load(requestedFile);
importFile.addEventListener(Event.Complete, htmlloaded_fn);
function htmlloaded_fn(event: Event): void {
displayText.htmlText = importFile.data;
}
addChild(displayText);
The event property COMPLETE should be in uppercase:
By convention all static properties of a class are written in uppercase with underscores between words.