Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Controlling flashmovies in html frames.

Posted on 2004-09-22
7
Medium Priority
?
222 Views
Last Modified: 2010-04-03
I want to have a menu bar created with flash in the top frame of my html page.  I want the buttons (ie home, links, contact us) to change the movie that is played in a specific frame of my html page.  basically once the home page is loaded.  I want to be able to click on contact us and the page doesn't reload just the movie in a specific cell loads and plays.  how do I do this?
0
Comment
Question by:liv4fun
  • 2
4 Comments
 
LVL 4

Expert Comment

by:mrdilliard
ID: 12128243
Congratulations, you get to use the LocalConnection object.

I would go through and explain it, but Macromedia's done a pretty good job already.

http://www.macromedia.com/support/flash/ts/documents/localconnection.htm
0
 

Author Comment

by:liv4fun
ID: 12129076
Can you give me an idea of what the scripting would look like for telling a movie to go to and play a specific scene in the movie that is already loaded in a different frame on my web page?
0
 
LVL 4

Accepted Solution

by:
mrdilliard earned 1000 total points
ID: 12130249
sure...

In your main movie that's receiving the commands, put this code on your first frame.
lcReceiver = new LocalConnection ();
lcReceiver.ChangeScenes= function (scene) {
         _root.gotoAndPlay(scene,1); //moves you to frame 1 of the scene you pass in.
};
lcReceiver.connect("lcConn"); //call lcConn whatever you want, just make sure it's the same in the sending movie.

In your sending movie, put this code on the frames where your buttons show up

mcButton.onRelease = function(){
         lcSender= new LocalConnection();
         lcSender.send ("lcConn", "ChangeScenes", "Scene 2");
}

Is that what you needed? By the way, you can use a LocalConnection between frames, between browsers, between swfs and between projectors, and between any combination of two, as far as I know.
0
 
LVL 39

Expert Comment

by:blue-genie
ID: 12130857
if i understand you correctly, you want to have a flash navigation in one frame control the flash movie in another frame?

if thats the case, you can also simply use javascript, parse a frame number through to it.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

I come across a lot of question about how to access things in the document class from a movieclip, or accessing something from a movieclip in the document class. It took me a while to figure this out but once I did it makes life so much easier. …
There are times in your Flash CS4 application when you want more than a simple pointer or a hand, and it's hard to find an ideal walk-through to tell you what to do.  I spent a few days recently learning my way around making custom cursors in Flash,…
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 select which audio input to use. Once you have an audio input plugged into the laptop or computer, you will go into the audio input settings and choose which audio input you want to use.
Suggested Courses

580 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