A Flash Developer Resource Site

Results 1 to 12 of 12

Thread: How to call variables?!

  1. #1
    Senior Member
    Join Date
    Sep 2000
    Posts
    183
    hi
    I have got a variable loaded from a cgi script into level0 of an MC. This MC(1) is placed inside an another MC(2) which is inside another MC(3) which is placed on the main movie. I now need to call this variable in a frame action from MC(2). What is the variable called?
    In the cgi file it is called "choice".

    How do i call it?

    Thanks in advance

    Ash
    [Edited by ashwinv on 07-05-2001 at 05:42 AM]

  2. #2
    its called _level0/:choice

  3. #3
    Senior Member
    Join Date
    Sep 2000
    Posts
    183
    Hi
    Thanks for the help but...
    It didn't seem to work. I don't know why.
    Any other suggestions?

    Thanks
    Ash

  4. #4
    Plz copy and paste the code which is not working.

  5. #5
    Senior Member
    Join Date
    Sep 2000
    Posts
    183
    Hi
    Code:
    Begin Tell Target ("../vote/bar1")
    Go to and Stop (_level0/:choice1)
    End Tell Target
    I think it is not working because the variables are loaded to level0 of an MC and not on the main movie. The MC which loads the variables is in an MC (which calls these variables) which is in an MC. And this MC is on the main movie.

    Thanks

    Ashwin

  6. #6
    try this...
    Code:
    Begin Tell Target ("../vote/bar1")
    Go to and Stop (eval(_level0/:choice1))
    End Tell Target

  7. #7
    Senior Member
    Join Date
    Sep 2000
    Posts
    183
    No luck


  8. #8
    OK, you do not need to use eval. Now there are two things you should check. First, that choice is actually present in level0 (try putting a textfield named choice to see its value displayed). Second, Check your tell target path
    Begin Tell Target ("../vote/bar1") is correct.

  9. #9
    Senior Member
    Join Date
    Sep 2000
    Posts
    183
    Hi
    The Tell Target works fine as i checked it by acually putting a frame number and it actually went to that.
    When i added the text box the information did not come up.
    Is level0 of any MC have one tag or do i have to specify it by telling which level0 it is.
    What if instead i loaded it to the target where i require the variable. If that is easier here is the layout again (as it is pretty confusing).
    • On Movie X there is MC(A1).
    • Inside MC(A1) there is MC (B1)
    • Inside MC (B1) there is MC (C1) - MC(C1) contains the loop which should load the variables to the MC(b1).


    If I now load the variables to the target MC(b1) from MC(c1)
    what is its label???

    Really hope we can sort this out!!


    Thanks in advance

    Ash
    [Edited by ashwinv on 07-05-2001 at 11:22 AM]

  10. #10
    _level0 is always your main timeline. You should check your cgi script, it seems that you are not receiving the variable from your cgi script into your flash movie.

  11. #11
    Senior Member tonypa's Avatar
    Join Date
    Jul 2001
    Location
    Estonia
    Posts
    8,227
    I think it's actually like this:

    Begin Tell Target ("../vote/bar1")
    Go to and Stop (_level0:choice1)
    End Tell Target

    See the difference, not like yours (_level0/:choice1)

  12. #12
    Senior Member
    Join Date
    Sep 2000
    Posts
    183
    Thanks for the Help
    Got it to work, by loading it to a target instead of a level.


    Thanks Again

    Ash

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