I can't seem to het the ReleaseA() working. Can someone help?
var cuAct:Number=0;
for (var asor:Number=1; asor<11; asor++) {
this.iasor=asor;
if(_root["asy"+asor].text!="") {
cuAct = cuAct+1;
_root.Accesso_summ.content_mc.acZ1.attachMovie("iconZ","ico nZ_mc"+cuAct,_root.Accesso_summ.content_mc.acZ1.getNextHighestDepth()) ;
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct].acZm_t x.text = _root["asy"+iasor].text;
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct].acZm_m c = "http://www.myweb.com/images/pimage"+iasor+".jpg"
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct]._x = xPosition2;
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct]._y = yPosition2;
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct].acZm_m c.onRelease = ReleaseA;
yPosition2 = yPosition2 + 18.7;
}
}
function ReleaseA() {
// trace ("yes")
_root.acc_prev_mc1._visible=true;
loadMovie(this.acZm_mc, _root.acc_prev_mc1.acc_prev_mc2);
}
In your for loop you are doing two seemingly unrelated things with acZm_m.. First you are treating it like it is a String variable, then you are treating it lke it is a movieclip. It cannot be both, and a String is not an interactive object.
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct].acZm_mc = "http://www.myweb.com/images/pimage"+iasor+".jpg"
...
...
_root.Accesso_summ.content_mc.acZ1["iconZ_mc"+cuAct].acZm_mc.onRelease = ReleaseA;
one of those lines has to change. The first is disallowing the second because it is redefining the object as a String.
North America
Europe, Middle East and Africa
Asia Pacific