Solved

How to use ScrollPane to scroll movie clip which we duplicate

Posted on 2004-04-06
7
11,553 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
[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
  • 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

Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
How do i create a Class that can control the main stage in action script 1 50
Flash Converter 8 142
flash in chrome 4 141
Adobe Connect add-in only works in admin accounts 4 38
Sometimes you know that one object has a specific child in it, but you can't find the child. This happened to me when I was trying to code some actionScript to make a toolbar work with its embedded buttons.  My partner had created the toolbar usi…
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.
Suggested Courses

737 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