Solved

Dynamically create a movieClip and put it into a scrollPane?(urgent)

Posted on 2006-07-16
4
298 Views
Last Modified: 2010-04-03
I have dynamically created a movieClip and would want to put it into a scrollPane object?
Here is the code i have written

m_oScrollPane =_root.createClassObject(ScrollPane, m_mcParent+"oScrollPane", _root.getNextHighestDepth());
m_oScrollPane.setSize(420,100);
m_oScrollPane._x = 0;
m_oScrollPane._y = 400;

Here i have created a Movie Clip m_mcCheckList dynamically through code
Now i want to attavh it to the scrollPane object
If i use m_oScrollPane.contentPath = "m_mcCheckList"

i get the following error
Error opening URL "file:///D|/Experios/Script%20Files/Science%20Slueths/m_mcCheckList"

Please help me attach this dynamically created movie clip to hte scroll pane
It is very urgent
Thanks in advance.
0
Comment
Question by:ashugarg00
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 5

Accepted Solution

by:
lupuleine earned 500 total points
ID: 17120331
hi,

there are only 3 things that you can attach to a scroll pane ... is an external JPG,  an external SWF and a movie clip from the library ...
that means that the movie clip has to be in the library, you can't attach an instance of a movie ...

now, a workaround for you would be to have in the library a container-like movie clip with linkage ... you attach this container movie to your scrollpane ... and you create dynamic movies inside the container ...

Lupuleine
0
 

Author Comment

by:ashugarg00
ID: 17120639
Thanks
I have added a movie clip in library named test
Now i do m_oScrollPane.contentPath = "test"

and i get an instance of movie clip named var mcScroll:MovieClip = m_oScrollPane.content;

Now i create all the other movie clips in the mcScroll Movie Clip and it works

Thanks once again for the answer
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Recently, I was asked to recommend a tracking system to be implemented on a clients website. As the entire site was built on flash, my first thought was to suggest custom built tracking system. However, our company at that point of time didn't h…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
The goal of the tutorial is to teach the user what frame rate is, how to control it and what effect it has on the video.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question