ActionScript 3.0 :: Referencing Objects In Captivate?

Jul 6, 2009

I need to be able to dynamically position a component generated in Captivate 4 via ActionScript that in child SWF that is imported into the Captivate project. The problem is that I don't know how to reference the objects in the parent movie. I can set a label on the object and reference the parent itself with:

MovieClip(this.parent)

but this doesn't seem to work:

MovieClip(this.parent).label.y

And I suspect that it is because some how Captivate subclasses the objects but I'm having trouble finding out how the hierarchy is structured.

View 2 Replies


Similar Posts:


ActionScript 2.0 :: Referencing Objects Not On Same Layer

Jul 15, 2011

Is it possible to control an object/element on a instance? If so, how is it done through actionscript?

There is an instance "instance140" off of the root, that has an element named img4 that i need to reference... does anyone know how I would go about that?

View 1 Replies

ActionScript 3.0 :: Referencing Objects In Array?

Feb 25, 2010

I've created a for loop to do the following:add instances of button MovieClip from library to stagename the instances via name propertyadd instance names to array for later referenceadd event listenershese 4 steps are working peachy, however, I'm having troubles referencing these instances later on through my code. I'm pretty sure that the problem is in my data types not matching, but I'm not sure how to fix it.

var menuBtn:mc_menuBtn;var menuBtnList:Array = new Array();
for(var b:int = 0; b < numFiles; b++){  //add instances to stage  menuBtn = new mc_menuBtn();  testClip.addChild(menuBtn); //adding button instances to

[code].....

View 5 Replies

ActionScript 2.0 :: Referencing Objects By Variable Name

Jan 11, 2007

I have a simple function that dynamically creates text fields. My text field name is referenced by var thisTextField. Problem is, when I try to do things with my text field, actionscript shoots back an error as such: There is no property with the name 'text'. How am I supposed to apply properties to my object if my objects name is a variable?

Code:
function showProducts() {
var products:Number = 0;
var thisTextField:String = "product" + products + "_txt";
for (var itemID in _global.rtsData[_global.rtsPos]["products"]) {
[Code] .....

View 2 Replies

ActionScript 3.0 :: Referencing Stage Objects From Within Class

Sep 3, 2009

How to access stage elements from within a class.
buttonControls.as

Code:
package {
import flash.display.Sprite;
public class buttonControls extends Sprite {
// Navigation Hover Color
var hover = "0xF1E960";
var normal = "0xFFFFFF";
public function changeColor(object, color){
[Code] .....

View 2 Replies

ActionScript 2.0 :: Referencing Objects From Inside A Function?

Jun 18, 2011

I understand this, _parent keywords and its usage but I don't understand the following:

MovieClip.prototype.move = function() {
function toRight() {
this._x=50;

[code].....

View 3 Replies

ActionScript 3.0 :: Referencing Objects That Are Not Present On Frame 1 Of A Movieclip

Apr 20, 2010

I'm working with a movieclip right now that has two frames in it. I want the user to be able to go back and forth between the pages by clicking on tabs on either page. The button that they click on is only present on the frame that it is applicable (so, the button to switch to frame 2 is only present on frame 1, and vice versa).

I want to control when they are able to click back and forth, and be able to turn the buttons on and off whenever I need to, but since the button to switch back to frame 1 is only on frame 2, when I reference it from the main timeline, the button registers as a null object. How do I refrence an object that is not present on the first frame of a clip?

[Code]....

View 3 Replies

ActionScript 3.0 :: Referencing Variables/objects From External FLA Files?

Dec 1, 2010

I am trying to display in 'Reciever.swf' the value a shared object updated in 'TextSO.swf'. The following is my code for the Reciever

Reciever.as-----------------
package {
import flash.events.SyncEvent; import flash.events.NetStatusEvent; import flash.events.MouseEvent; import flash.net.SharedObject; import

[Code]....

I am getting an error that says that 'text_so' is an undefined property and that I can't access it. Yes, I have not declared 'text_so' in 'Reciever.as'. However it is the shared object instance from the 'Text_SO.as' file. How do I reference it from the 'Reciever.as' so that I won't get this error anymore?

View 1 Replies

ActionScript 3.0 :: Referencing Objects In The Level Above The Movie Clip?

Sep 10, 2011

i want to referance objects in the level above the movie clip that i have the AS in.  what i mean is that i have a movie clip on the stage, and that movie clip has some actionscript in it, and that AS needs to refer to an object on the main stage, how would i do that?  i have tried parent and stage 1, but neither seem to work

View 4 Replies

ActionScript 3.0 :: Referencing Variables / Objects From External FLA Files?

Dec 1, 2010

I am trying to display in 'Reciever.swf' the value a shared object updated in 'TextSO.swf' . The following is my code for the Reciever[code].,...

I am getting an error that says that 'text_so' is an undefined property and that I can't access it. Yes, I have not declared 'text_so' in 'Reciever.as'. However it is the shared object instance from the 'Text_SO.as' file. How do I reference it from the 'Reciever.as' so that I won't get this error anymore?

View 4 Replies

ActionScript 3.0 :: Dynamically Referencing Objects Names In Loop

Jul 12, 2009

The problem is referencing object names dynamically in AS3, in a loop. Example. I have an array called c4 which i would like to reference like this:

I have a number
var x:Number = 4

How can I do something like
trace(["c"+x].length);
(I know this is wrong!)

Same with other objects
E.g. Movieclip called mc4
["mc"+x].x = 100;

View 3 Replies

ActionScript 3.0 :: Object Oriented Game - Referencing Dynamic Objects

Jun 26, 2009

I'm doing this object oriented game and I create a bunch of 'boxes' via a for loop

Code:
Select allfor (var z=0; z < numOfBoxes; z++){
var box:Object = new Object();
box.mc = new Box();
box.mc.name = "box"+z
box.mc.x = Math.round((Math.random()*(530-box.mc.width)) + 20);
for (var i=0; i<boxXArray.length; i++){
[Code] .....

I get my random amount of boxes scattered over my stage (I haven't put in any checks to see if they are touching). How do I 'name' these boxes so I can reference them later? Say I want to move the .x of boxA in another function? Is there a simple way to call them box+z instead of just all as box? (Then I can run them through a loop later to talk to them).

View 2 Replies

ActionScript 3.0 :: Referencing Class Objects From Class?

Jun 19, 2010

I have an enemy on the stage that reads whether it's being hit by a bullet by a hittest. There's a for loop inside the enemy's class that looks for all the bullets and names the bullet that's hitting it "hitBullet". What I'd like to do have an easy way of seeing what type of bullet is hitting the enemy. I'm basically looking for something like

if (hitBullet == RegBullet) {
//do regular bullet dying
}else if (hitBullet == ClusterBullet) {
//do clusterbullet dying
}

, where RegBullet and ClusterBullet are classes. But I have no idea what hitBullet is equal to when a ClusterBullet or RegBullet hits it. I traced hitBullet to see what it would return and got "[object ClusterBullet]", but I'm not sure what that would be in the actual code.

View 2 Replies

ActionScript 3.0 :: Captivate TOC On Top Of SWF?

Jun 17, 2011

In a Captivate 5 file, I imported a Flash AS3 file. I added the Flash file to the first Captivate slide and set the swf properties to display for the entire project. Essentially the Flash file is a skin/interface for the Captivate file. Everything is working fine, but the TOC is on top of the skin.

The scenario worked fine with Cativate 4 and AS2. The Flash skin has a TOC button. When the button is clicked, the TOC opens beneath the skin.

How can I position the TOC in the display list?

View 0 Replies

ActionScript 3.0 :: Pass Captivate Variable?

Aug 18, 2010

I used the following code on a frame within an swf that was imported  to a CP4 slide. This worked fine in as2. I'm wondering how to write the  same code in as3.
 
_parent._parent._parent.rdcmndNextSlide = 1;

View 2 Replies

ActionScript 2.0 :: Captivate Accessible In Flash

Jul 24, 2009

I've got Captivate movies dynamically loading into a Flash movie. The problem is, the tab index which works so well when the Captivate movies are in stand-alone mode falls apart when loading the Captivate movie into a Flash shell. I've tried tabEnabled=false and tabChildren=true for the movie clip that contains the Captivate movie, but with no results. Does anyone know how to get the focus manager to tab to objects in a Captviate movie when that movie is running in a Flash shell?

View 1 Replies

ActionScript 2.0 :: SWF Not Working When Imported Into Captivate 4?

Sep 30, 2009

i have produced a simple drag and drop slide for use in my captivate project, works fine standalone, but when i import into Captivate it doesnt work correctly, the drag and drop element works ok but it doesnt seem to be targeting the drop target i then use to then goto the next frame etc.

on (press) {
startDrag(this, true);
}
on (release) {

[Code]......

is there another way to reference "/want_box" that will work in Captivate?

View 1 Replies

ActionScript 2.0 :: Loading Swf Created In Captivate 4?

Dec 24, 2010

I have created a .swf using Captivate 4. When I try to load the swf into a Flash project - (AS2) I get the following output:

Branching::script:;;
deepak branching : scripteval:[object Object];

I rewrote the Flash using components and the same thing happens. So, I'm thinking it has something to do with how Captivate makes the .swf.

View 9 Replies

ActionScript 1/2 :: Controlling Embedded Captivate SWFs

May 25, 2006

I have a SWF (SWF A) that I'm loading into a movieclip (Movieclip C)which is part of another SWF (SWF B). Basically, SWF B functions as a player, with play and pause controls. These controls control Movieclip C where the external SWF A is loaded into.Normally, I have had no problem with this and it always works. At run time, when you click the pause button on SWF B, a stop() command is issued to Movieclip C, which stops the play of
the external movieclip (SWF A) loaded into it.However, I did a screen capture with Captivate and published it as a SWF. I loaded this SWF (SWF A) into Movieclip C in SWF B at run time. However, clicking the controls on SWF I created has NO EFFECT on the SWF I created in Captivate. It just keeps playing.I guess all SWFs are NOT created equal. How can I make this work?

View 4 Replies

ActionScript 1/2 :: Control Captivate 5 Swf Files With As3 In Flash Cs5?

Jun 15, 2011

I have a custom build swf player, which has basic functions of play, pause, quit etc. It plays swf created with flash. I created a demo using captivate cs5, then exported it to flash. The captivate swf does not works with my swf player, it loads and starts playing but play and pause button does not work at all with it.[code]...

View 7 Replies

Professional :: Play Pause Widget Captivate?

Jun 16, 2011

I have read a lot of threads on this, and I am trying to create a widget that will allow the button to toggle between Play/Pause pictures and play and pause the captivate as necessary.Right now my script reads as below: The button will toggle bwteen play and pause pictures. But will not pick up the .rdcmndPause=1; .rdcmndResume=1.

this.Pause.visible = true;
this.play1.visible = false;
this.play1.addEventListener(MouseEvent.CLICK,hidePlay);

[code]......

View 2 Replies

ActionScript 3.0 :: Unable To UnloadAndStop Captivate 5 Swfs?

Jul 8, 2011

have a flash 'menu' swf that on the click of a button loads into a loader a flash 'controller' swf. This swf in turn loads into a loader a 'captivate 5' swf. All published to fp10.exit the captivate movie the user can click on the menu button (which resides on an area of the 'menu' swf below it), and I have coded to UnloadAndStop and StopAllSounds of the 'controller' swf loader.his works, everything goes, the loader 'unloads' and it does stop the  sound of the current captivate slide, but then audio from the captivate movie will fire up again from the next slide and continue to play over the menu

View 24 Replies

Flash :: Captivate 5: Call A Nested Swf Inside A Swf?

Jun 30, 2011

i'm using captivate 5 to create an elearning project, due to captivates limited animation abilities i created a menu bar in flash and imported it into captivate as an swf. The menu bar has a glossary listing that whne clicked calls upon another swf which is a glossary.

The problem is that the glossary swf doesnt pop up when the glossary listing is clicked inside of captivate. The menu bar works perfectly outside of captivate. the glossary is already made in AS3. So my question is can you call a nested swf within captivate?

View 1 Replies

ActionScript 3.0 :: Possible To Fetch Captivate 4 Score Into Flash?

Jan 5, 2010

I wonder whether anyone knows of a solution to this: I want to embed a Captivate 4 quiz in a flash CS4 file and retrieve the score from the Captivate SWF so that I can use it in my flash file (AS3)- does anyone know a way of doing this (?eg. shared objects?). Communication between Flash and CP seems to be a lot more problematic than I anticipated.

View 0 Replies

ActionScript 2.0 :: Captivate 4 Widget To Mute Sounds?

Jun 24, 2010

We do not use the playbar for our projects.. we use independent buttons.I struggled making a widget /button for Captivate 4 that would Mute/Unmute all sounds... In case you are struggling too... here is the code that worked for me:(you will need to know how to make a widget)

var soundOn:Boolean = true;
var globalSound = new Sound(_level0);
muteOffOn_btn.onRelease = function(){[code]....

View 0 Replies

ActionScript 3.0 :: Passing Variable Value From Captivate 5 To Flash CS5

Jan 9, 2012

I don't get it Why is it so difficult to pass a variable from Captivate 5 to AS3/Flash CS5. I have a variable (gpDone = 1) in Captivate 5 (it's a guided practice) on the last frame which will indicate that the learner has completed the guided practice file. Now I want to pass that variable back to Flash/AS3 so I can evaluate whether I should show the Continue button so they can continue. They have to complete the guided practice before they can continue. If it is equal to 1, the Continue button will display. If it is not equal to 1, the Continue button will not display, but a message will display telling them they have to complete the guided practice in order to continue in the course.

View 0 Replies

ActionScript 3.0 :: Flash - Captivate Swf To Close When Its Done Playing?

Mar 9, 2011

I've developed a menu in AS3 with about 10 buttons. Each buttong will load an swf or a swf created in Captivate. I want the swf to load ontop of the menu, then close when it's done playing. I can get this to work fine with swfs created in Flash, but not captivate 5. The captivate file will open and play, but it won't close.I tried adding the script at the bottom to an swf and importing that into the last slide of captivate with no luck.This doesn't seem like it should be so tricky.Here is some of the AS3. I didn't bring the code in for all the buttons.

var swfLoader:Loader = new Loader;
introduction_to_gcssj_btn.addEventListener(MouseEv ent.CLICK, introductionClicked);
portal_features_btn.addEventListener(MouseEvent.CL ICK, portalFeaturesClicked);

[code].....

View 1 Replies

ActionScript 3.0 :: Pausing A Captivate Movie That Has Been Imported Into Flash?

Jan 10, 2010

Basically I need to pause a Captivate movie (CP3) that is playing within a flash movie (CS4, AS3).
 
I have made a full motion recording with Captivate which I have imported into a flash movie. The flash movie is organised as a series of movieclips that play from the main timeline. My CP demo forms part of one of these movieclips (there are flash objects playing "on top" of it in different layers). I have a play/pause button on the main timeline that works to pause all of my movieclips EXCEPT for my captivate demo. This continues playing, while the movie clip is forms part of pauses, throwing everything out of sync.
 
how I can pause CP portion? My actionscript skills are minimal and I'm not even sure what object(s) to target.

View 2 Replies

ActionScript 3.0 :: SoundMixer.stopAll Not Working With Captivate Content?

Aug 10, 2010

am building eLearning courses using a Flash-based AS 3.0 course playerI use SoundMixer.stopAll to stop sounds when progressing through the course, pressing buttons etc also call SWFs made in Captivate into my courses. These SWFs have audio in them. But when I progress through these slides (by clicking a next button), the sound from the captivate made slides overlaps (keeps playing). SoundMixer.stopAll does not seem to work for captivate SWFs

View 1 Replies

Actionscript :: Captivate Playback Control Skin In Flash?

Nov 4, 2009

How can I create and control Captivate Playback Skin in Flash with my custom layout and script?

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved