Hello,
I followed the steps in the **CSS Tutorial **and it worked fine to call and display external text with CSS. However, as soon as the script and dynamic text box was placed into a graphic symbol or a movie clip it did not show up.
Any thoughts?
I used a Dynamic text box as explained in the tutorial (with Instance name “Output”) and used the following actionscript (in the layer above):
var format = new TextField.StyleSheet();
var path = “http://www.kirupa.com/developer/mx2004/code/flash.css”;
format.load(path);
format.onLoad = function(loaded) {
if (loaded) {
output.styleSheet = format;
myLoadVar = new LoadVars ();
myLoadVar.load(“kirupa.txt”)
myLoadVar.onLoad = function (success){
if (success == true) {
output.variable = “kirupa”
output.htmlText=myLoadVar.kirupa;
}
}
} else {
output.text = “Error loading CSS file!”;
}
};
-Foley.