Solved

LoadMovie into temporary movieclip inside a movieclip.... or call a function inside a movieclip that has an external swf loaded into it

Posted on 2009-05-07
7
348 Views
Last Modified: 2013-11-11
Hello Experts,

In my main fla, I have a movie clip holder called mc_temp1, into which I load an swf file called myMovie1.swf.

The movie clip myMovie1.swf contains another movie clip holder called mc_bio,into which I am want to load and unload more swf files.

From my fla, can I call mc_bio and perform LoadMovie and UnloadMovie on it?

If not, then, how can I call a function inside myMovie1.swf? (This will also work, because I can write a function inside myMovie1.swf that will load/unload movies to and from mc_bio.)
0
Comment
Question by:bscny
  • 3
  • 3
7 Comments
 
LVL 39

Accepted Solution

by:
blue-genie earned 500 total points
ID: 24335433
yes you can. if your script is in your main.fla you just need to target the objects properly.
what are you trying to achieve though, as you might start getting yourself into a tangle eventually with loading things into multiple levels.
0
 

Author Comment

by:bscny
ID: 24355039
Hi blue-genie,

I am attaching a layout of the site. You can see from this file that the navigation is located in main.fla. Main.fla has two movielcips inside it, and based on what menu item is chosen from main.fla, different swf files load into the empty movie clips.... That part is working fine, but now I am have added some buttons to an swf that is loaded into the second movie clip... and from there, I am trying to control elements of the swf that is loaded into the first movie clip.... but because I am still new to actionscript, I don't know how to properly call the element I am trying to control.

site-layout.jpg
0
 
LVL 39

Expert Comment

by:blue-genie
ID: 24373066
first of all. what version of AS are you using?

secondly.
I pick menu item 1 from main - it loads mymovie1 into mc_temp1
if i pick menu item 2 it loads mymovie2 into mc_temp2.

where are the 2 temp movieclips in relation to each other. Why do you have 2? do they appear at the same time or does one replace the other.

then you say "I am trying to control elements of the swf that is loaded into the first movie clip" - what does that mean? give me an example.

blu.
0
Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

 

Author Comment

by:bscny
ID: 24397653
Hi Blue-Genie,

I am using AS2.

I pick menu item 1 fro main, it loads an swf into mc_temp1, and a different swf into mc_temp2.  The layout you see in the picture, is what the site looks like.

Everything was going ok, until eventually, I came across having to load an swf with buttons into mc_temp2... so in the example above:

these buttons onrelease would need to load new text into the swf already loaded into mc_temp1.... but instead of completely replacing the swf in mc_temp1, I decided ot nest another swf inside the swf loaded into mc_temp1....

So it should work like this:
1) press menu_item1 on main... this will load myMovie1.swf into mc_temp1 and myMovie2.swf into mc_temp2
2) press button1 inside myMovie2.swf.... OnRelease, this button should load an swf (lets call it bio1.swf) into mc_bio. mc_bio is a movieclip inside myMovie2.swf
0
 
LVL 39

Expert Comment

by:blue-genie
ID: 24401544
ok so the answer is yes you can do it.
if you have problem implementing upload your file.
0
 

Author Comment

by:bscny
ID: 25585158
The diagram above was just an example. I don't have an actual fla that I can upload.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

This article describes a solution to a problem of subloading one movie into another when they have different SWF versions. Sometime back, I was working on an ActionScript project while I came across an interesting fact which I would like to share…
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…
The goal of the tutorial is to teach the user how to how to load their YouTube profile onto Flash Media Live Encoder.
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.

813 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now