All pastes #827347 Raw Edit

Stuff

public text v1 · immutable
#827347 ·published 2007-12-21 18:30 UTC
rendered paste body
function handleclip(id:String,flag:Boolean,depth:Number)
{
	trace(curravatar);     //This holds the string 'Avatar1_MC'
	Avatar.curravatar.removeMovieClip();  //Doesn't work. I think the STRING value of curravatar is problem.
	Avatar.attachMovie(id,id,depth);
	Avatar.id.Height=old_height;
	Avatar.id.Width=old_width;
}



If I change , Avatar.curravatar.removeMovieClip();  to Avatar.Avatar1_MC.removeMovieClip();  , it works. How do I use the variable curravatar in this case ?