Can't Remove Dynamically Created Symbol Instance
hi all,
i have symbol instance called library using trigger:
var stopall = sym.getcomposition().getstage().getsymbol("comb").getchildsymbols();
for(var i=0; i<stopall.length; i++) // return number of direct children
stopall[i].stop();// create instance element of symbol child of the
var chromo1 = $(sym.createchildsymbol("peak1_1", "stage").getsymbolelement());
chromo1.css({marginleft:175, margintop: 500});
this correctly stops symbols within main symbol playing , positions symbol instance "peak1_1" on stage.
then, within symbol instantiated ("peak1_1") have button symbol "closechromo1" following actions
var startall = sym.getcomposition().getstage().getsymbol("comb").getchildsymbols();
for(var i=0; i<startall.length; i++)
startall[i].play();
sym.getcomposition().getstage().sym.$("peak1_1").remove();
the first 3 lines work , restart stopped child symbols.
the fourth line, should remove instantiated symbol stage doesn't work. have tried referencing instance name ("chromo1"), , hiding using getsymbolelement, doesn't work. have tried using deletesymbol() , referencing entire symbol tree, starting composition level, , doesn't work. have tried possible variations can think of, including referencing through children , parents -- still no joy.
what doing wrong?
thanks in advance help!
matt
check how symbol removed in sample:
More discussions in Edge Animate CC
adobe
Comments
Post a Comment