Solved

How to use ScrollPane to scroll movie clip which we duplicate

Posted on 2004-04-06
7
11,552 Views
Last Modified: 2012-06-22
The function of scrollPane is used to scroll the movie clip, but we must define the identifier name in linkage which from library right. From there i know how to scroll it.

But now the problem is, if i would like to scoll movie clip which duplicate from action script. Example, inside library got one movie clip name M1 contains a textField T1 and T1.text = "Hello". Now u dulipcate it and change the T1.text = "How are you". So inside my stage got two movie clip now. So how i can set the scrollPane content to scroll?

For my information, i know that scrollPane only scroll the movie clip which having linkage identifier name. So the movie clip i duplicate is possible to set the linkage identifier name for it?

Please help me to solve this question with clear description.
0
Comment
Question by:MaxTo
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 19

Expert Comment

by:Montoya
ID: 10765599
It should work exactly the same. I just used duplicateMovieClip
You can get an example here:

http://www.realinteresting.com/flashexperts/scrollpanetest.fla


Hope that helps.
0
 

Author Comment

by:MaxTo
ID: 10771705
To Iammontoya,

i believe that your example can help me, but after i download it, i can't open it. i was using Flash MX. is it your example i writing using Flash MX 2004.

Is it possible, write down main code for me. if this was work as what i want, i will accept it as answer. THanks

frm
Max
0
 
LVL 19

Expert Comment

by:Montoya
ID: 10771729
blue_btn.onRelease = function() {
      _root.sqr_mc.duplicateMovieClip("sqr_mc"+2);
      sqr_mc2._x = 390;
};

I did not get a chance to test it w/ Flash MX, but Im sure it will work out fine.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:MaxTo
ID: 10772369
After i saw the example of you. Sorry to said that it wasn't what i want.
Maybe my description no details. Here i descript it more details.

in the program library i got one scrollPane name SP.
one movie clip name MC contains one textField name txt1. (ps : SP not in movie clip)

when i press button 'It will duplicate MC name MC1 and MC1.txt1 = "hello", so now
what i want is the SP scroll content is scroll MC1.
i press button again will duplicate again and name MC2 and MC2.txt1 = "Thanks",
now i wanna set the SP scroll content will change to scroll MC2.

In this stage only got one scrollPane, but will got many movie clip. and each movie
clip textField or picture will be different. And library only got one movie clip.

Hope you can help me.

Max
0
 
LVL 9

Accepted Solution

by:
krishnaprathab earned 250 total points
ID: 10772941
Hi Max,

Its actually very simple. Follow the steps listed below and it WILL work ;)

1) Create your movieclip(MC) on the stage , go inside it and create your text field (txt1).

2) Now goto the main timeline and delete the mc movieclip from the stage.

3) Press Ctrl+L and in the library right click on the mc movieclip and select "Linkage..."

4) Click the "Export for Actionscript" checkbox and specify mc as the identifier.

5) Now come to the main timleine and place this action :

my_scroll.setScrollContent("mc1");

This will load your file into the scroll pane as you would like to do.

If you want to attach a duplicated movieclip into the scrollpane then,

mcRef = mc.duplicateMovieClip("mc"+2);
mcRef.txt1.text = "hello";
my_scroll.setScrollContent(mcRef);

Hope this helps !

Thanks,
KP
0
 
LVL 9

Expert Comment

by:krishnaprathab
ID: 10772953
You can also refer to a similar question answered by me present at :

http://www.experts-exchange.com/Web/WebDevSoftware/Flash/Q_20934077.html#10706064

Thanks,
KP
 
0
 

Expert Comment

by:haidozo
ID: 11100029
Is setScrollContent() an old function replaced by contentPath() in MX2004?  Anyway, is there a way to create a movie dynamically and place that in the scrollPane with MX2004?


0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Stop Ads in Browser Google Chrome 3 550
Install adobe flash plugin for Firefox win 7 9 71
Web browser crash when play videos 24 382
You Tube Videos not playing 9 134
Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
While working over numerous projects I often had the requirement for doing a screen capture in AS3.0. Unfortunately I found no "ready made" solutions in google search that suited my requirements. But I did come across some great resources which help…
The goal of the tutorial is to teach the user how to set there setting in Adobe Flash Media Live Encoder and YouTube for optimal video and audio quality.
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.

680 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