A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: How do you change AS array data from main timeline?

  1. #1
    Junior Member
    Join Date
    Mar 2011
    Posts
    26

    How do you change AS array data from main timeline?

    Let's say I have a file that loads an AS. Within that AS is an array that loads to a list menu in the main file or .fla. The list menu is used as navigation, so when the user clicks on one of the items, in the list, it goes to, let's say, frame 2.

    Now, on frame 2 I would like to change the information in the array so that the list menu now contains a new list of links.

    How would I change that data in the AS array within the main file's timeline?

  2. #2
    Junior Member
    Join Date
    Mar 2011
    Posts
    26
    bump

  3. #3
    Will moderate for beer
    Join Date
    Apr 2007
    Location
    Austin, TX
    Posts
    6,801
    How about instead of posting a vague description of your problem using non-standard terms, you post the code that is giving you trouble and tell us what the trouble is.

    To access an array, or anything else, you have to have a reference to it. That's all. There's no magic to it. Just get a reference to your array, and you can alter it. If you don't have a reference where you want one, then either figure out how you can get one, or figure out a different way of doing what you're trying to accomplish.

    In this case, it sounds like you want to cause a change in the root from something further down the display list. In that case, rather than crawling back up the display list it's probably better to dispatch an event and let anything interested handle that event.

    But it's impossible to tell, because we only have the vaguest description of your actual situation.

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