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
345 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
Comment Utility
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
Comment Utility
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
Comment Utility
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
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:bscny
Comment Utility
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
Comment Utility
ok so the answer is yes you can do it.
if you have problem implementing upload your file.
0
 

Author Comment

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

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Adobe Flash Player - PPAPI plugin 6 231
video live streaming 1 110
bandwidth 5 64
Web browser crash when play videos 24 202
This is intended to introduce all collision detection principles in flash, their strengths, weaknesses and workarounds. The main method for Collision Detection in flash is using hitTestObject. But unless you'll be pushing rectangular shapes without …
I have found that much of my time doing support ends up being a constant repetition of the same steps to different people.  Early on I stated using web pages with Frequently Asked Questions (FAQs) to alleviate most of the burden.  Sometimes this jus…
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 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.

762 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

11 Experts available now in Live!

Get 1:1 Help Now