[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

How to access/reference movieclip within flex application?

Posted on 2007-11-18
7
Medium Priority
?
1,621 Views
Last Modified: 2012-06-22
Hello experts!

I have a custom flash menu I have built using flash cs3.
It is basically a bunch of animated movieclips (onRollOver).

I am loading this Flash SWF through the use of a SWF loader in my Flex app.

How do I access the content of the flash swf??
I want to code something like (I know this is as2 but it's just easier to give the example):

flashswf.movieclip1.onRelease = function() {
     change state of main flex app to 'state1'
}

Do I have to code this in the flash swf? or can I use the flex swf to do so?

thanks!
0
Comment
Question by:bensarz
[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
  • 3
  • 2
7 Comments
 
LVL 23

Accepted Solution

by:
Siva Prasanna Kumar earned 1000 total points
ID: 20309852
According to me your Flash file must have all the required functionality as such it works when you its complete. But As per the documentation I suppose it says that these events will trigger on the Flash loaded. The whole SWF file is loaded is considered as a single component.

http://livedocs.adobe.com/flex/2/langref/flash/display/Loader.html 
0
 
LVL 23

Expert Comment

by:Siva Prasanna Kumar
ID: 20309862
I am not sure where you searching for this ? "Accessing SWFs from Flex and Vice-Versa"

http://weblogs.macromedia.com/pent/archives/2004/12/accessing_swfs.cfm
0
 
LVL 19

Assisted Solution

by:Gary Benade
Gary Benade earned 1000 total points
ID: 20310328
You have access to the loaded movies root through the content property, as long as the flash movie is actionscript 3 you can manipulate it directly eg. swfLoader.content.addEventListener( "yourFlashEvent", yourHandler);
swfLoader.content.someFunction();
swfLoader.content.someVariable = 3;
0
 
LVL 19

Expert Comment

by:Gary Benade
ID: 20329515
Did you get it to work?
0
 
LVL 19

Expert Comment

by:Gary Benade
ID: 22537975
Need more help with this?
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

Here are some practices and techniques that can be adopted into your Flash/Flex application development process. Note: Not all "performance tips" provide an immediately-recognizable benefit.   This article does not include timing validation data,…
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…
The goal of the tutorial is to teach the user how to how to record live broadcast.
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.

650 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