dcsimg
A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: can't attach dynamic MCs into a scrollpane

  1. #1
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36

    can't attach dynamic MCs into a scrollpane

    I'm looking to have dynamic content in a scrollpane... movie clips containing content from a database. (AS2, Flash MX 2004)

    I've been following the instructions on an older thread that I searched and found... http://www.flashkit.com/board/showthread.php?threadid=421720&highlight=scrollpan e+movie

    This is just a simple test, so I could understand it and get it working before I use it for my real project... but I can't get it to work. I've got my linkage properties set up, and I've triple-checked the names I've assigned.

    I've got an empty MC in the library called "block." The "mclip" MC just has a rectangle, for me to view results. If I put the "block" MC on the stage with an instance name of "block1," with the following AS it works... "mclip" appears four times.
    Code:
    for(i=0;i<4;i++){
    _root.block1.attachMovie("mclip", "mclip"+i, i);
    _root.block1["mclip"+i]._x = i*20;
    _root.block1["mclip"+i]._y = i*20;
    }
    But when I attempt to do the same in a scrollpane, I get nothing. Here there is no instance of "block" on the stage, just a scroll pane (instance myScrollPane).
    Code:
    for(i=0;i<4;i++){
    _root.block.attachMovie("mclip", "mclip"+i, i);
    _root.block["mclip"+i]._x = i*20;
    _root.block["mclip"+i]._y = i*20;
    }
    myScrollPane.contentPath="block";
    Obviously I'm missing something. A kick in the right direction would be most helpful!

  2. #2
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36
    --bump--

    (still hoping for some advice)
    Last edited by hermie; 08-10-2004 at 01:16 PM.

  3. #3
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36
    re-bump

  4. #4
    Member
    Join Date
    Apr 2003
    Location
    LA, CA
    Posts
    36
    I'm still hoping someone with scrollpane know-how will see this... sorry I keep bumping it.

  5. #5
    Junior Member
    Join Date
    Mar 2004
    Posts
    28
    Where are you putting that code? If you have the code on the root then it won't work unless "block" is on the stage. Try attaching "mclip" from frame 1 of "block".

    is this what you mean?

    block.fla

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