I have some code that is attempting to interact with a movieclip that resides further down the timeline, but can’t seem to do so no matter what I do. I’ve tried absolute and relative addressing, I’ve even sent the playhead to that frame before attempting to interact with the movieclip - nothing works. Am I going crazy here or am I missing some key ingredient? Please refer to the attached image - it shows the location on the main timeline where the code is (1) and where the MC is (2).
I will post a code snippet here:
function handleLoginResponse(re:ResultEvent){
trace("<handleLoginResponse>: we called login succesfully: " + re.result + " Going to loading screen");
gotoAndStop("loading");// moves playhead to frame where statusMC is
trace("statusMC current frame= " + statusMC._currentframe());// returns "undefined"
statusMC.gotoAndStop("loading");
// Authentication Successful
if( re.result == '0' ) {
gotoAndStop("loading");
statusMC.gotoAndPlay("success");// these two lines
statusMC.firstName.text = user;// work fine for some reason.
}
// Authentication Failure
else {
gotoAndStop("loading");
statusMC.gotoAndStop("failure");
}
}