A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: loop through movie clips?

  1. #1
    Member
    Join Date
    Aug 2003
    Posts
    43

    loop through movie clips?

    Is there a way that I can loop through the movie clips?

    For example.

    Instead of doing this:

    clip0._visible = true
    clip1._visible = true
    clip2._visible = true
    clip3._visible = true

    can I do something like this:

    for(i=0;i<4;i++){
    clip(i)._visible = true;
    }

    thanks for any info.

  2. #2
    Junior Member
    Join Date
    Apr 2005
    Posts
    9
    maybe eval:

    code:
    eval("clip" + i)._visible = true



    either that or:

    code:
    this["clip" + i]._visible = true


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center