Question
attachMovie fails
hi,
i'm trying to attach a symbol to a loaded clip so far unsuccessfully. i've
found older threads in this forum, tried to implement what i've found there,
but that didn't help either.
this is my basic code:
function loadLogo(lFile){
var mclLogo:MovieClipLoader = new MovieClipLoader();
var logoListener:Object = new Object();
logoListener.onLoadInit = function(target:MovieClip){
inv = setInterval(_level0, "loadComplete", 1000,target); // using
this interval to make sure the clip is completely loaded
}
mclLogo.addListener(logoListener);
mclLogo.loadClip(lFile,this.logo_mc);
}
loadComplete = function(_mc:MovieClip) {
var tt:MovieClip = _mc.attachMovie("toolTip","tt_mc",1);
trace(tt); // always returns 'undefined'
tt._visible = false;
_mc.onRelease = function() {
// some code
}
_mc.onRollOver = function(){
// some more code
}
_mc.onRollOut = function() {
// and here too..
}
clearInterval(inv);
}
loadLogo("logo.jpg")
// end of code
i have on the stage an empty movieclip 'logo_mc', and in the library a
symbol with the linkage identifier 'toolTip'.
the logo loads fine, but after a second in get in the message window
'undefined'
any tips?
thanks in advance,
eRez
www.cinabu.com
i'm trying to attach a symbol to a loaded clip so far unsuccessfully. i've
found older threads in this forum, tried to implement what i've found there,
but that didn't help either.
this is my basic code:
function loadLogo(lFile){
var mclLogo:MovieClipLoader = new MovieClipLoader();
var logoListener:Object = new Object();
logoListener.onLoadInit = function(target:MovieClip){
inv = setInterval(_level0, "loadComplete", 1000,target); // using
this interval to make sure the clip is completely loaded
}
mclLogo.addListener(logoListener);
mclLogo.loadClip(lFile,this.logo_mc);
}
loadComplete = function(_mc:MovieClip) {
var tt:MovieClip = _mc.attachMovie("toolTip","tt_mc",1);
trace(tt); // always returns 'undefined'
tt._visible = false;
_mc.onRelease = function() {
// some code
}
_mc.onRollOver = function(){
// some more code
}
_mc.onRollOut = function() {
// and here too..
}
clearInterval(inv);
}
loadLogo("logo.jpg")
// end of code
i have on the stage an empty movieclip 'logo_mc', and in the library a
symbol with the linkage identifier 'toolTip'.
the logo loads fine, but after a second in get in the message window
'undefined'
any tips?
thanks in advance,
eRez
www.cinabu.com