Skip navigation
Toe Cutter
Currently Being Moderated

movieclip visible

May 26, 2009 1:26 PM

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

 
Replies
  • Currently Being Moderated
    May 26, 2009 1:35 PM   in reply to 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.

     
    |
    Mark as:
  • kglad
    72,340 posts
    Jul 21, 2002
    Currently Being Moderated
    May 26, 2009 1:36 PM   in reply to Toe Cutter

    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.)

     
    |
    Mark as:
  • Currently Being Moderated
    May 26, 2009 1:59 PM   in reply to kglad

    That's usually my problem!

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points