Copy link to clipboard
Copied
Hi,
I have something in AS2:
stratBox1e.visible = false;
which I’m trying to translate to AS3.
I’ve read that layers can’t be made hidden anymore in AS3, but rather,
you now focus on making the movieclips hidden instead.
If that’s the case, how might I make “stratBox1e.visible = false;”
(where stratBox1e is the movieclip) work in AS3.
I currently get this error:
1120: Access of undefined property stratBox1e.
Thank you,
Toe Cutter
The code you show is AS3. Your problem is most likely that you have not assigned that as the instance name (in the properties panel) for that movieclip, or that code and that movieclip don't exist together in time.
Copy link to clipboard
Copied
The code you show is AS3. Your problem is most likely that you have not assigned that as the instance name (in the properties panel) for that movieclip, or that code and that movieclip don't exist together in time.
Copy link to clipboard
Copied
your as2 is as3. if that were as2, you would use _visible, not visible.
layers could never be hidden using actionscript. they can be hidden in authoring environment in cs3 and cs4.
an object with pointer stratBox1e doesn't exist when your code executes.
create an object (like a movieclip) and give it that instance name. retest.
(i should have known better than typing such a lengthy first response.)
Copy link to clipboard
Copied
That's usually my problem!