Test For .swf Completion
I am loading an external .swf file into a movie clip. When the .swf file has finished playing, I want something else to happen. Is there any way I can test to see when the .swf file gets to the end of it's main timeline? TIA, Carolyn
ActionScript.org Forums > ActionScript Forums Group > ActionScript 2.0
Posted on: 03-22-2007, 04:41 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Shape Completion Test?
Hi,
This task has been driving me crazy for the past two weeks...
I'm trying to figure out how to program a shape completion test and whether an object is inside that shape. I'm making a game where the goal is to draw a line around a moving opponent, trapping it inside.
Any ideas on how this can be done? If I end up using an idea/concept suggested by you, I'll definitely credit in-game.
Thank you!
On FLV Completion...
Hey Gang,
So I'm here programming in AS3. I am still pretty new to it, but I friggin' love it. So easy and nice!
Of course though, I have hit a snag I cannot get by.
I have an FLVPlayback going on and it works fine. It is on a movieclip and it plays when said movieclip is clicked. My issue is that after the video plays, if I try to play it again, it loads up but then just pauses and won't play (I don't have the play/pause controls built just yet, but the video should just play, there is nothing that should pause it).
Basically I call a play method which does this...
_flv.play(_source);
_flv.seek(180);
I am seeking because that's close to the end of the video and I'm really just working on the video complete code at the moment... Anyways, I just want the video to play again if it's clicked.
When the video has completed I have tried using
_flv.stop();
Which just gives me the same issue...
and
_flv.closeVideoPlayer(_flv.activeVideoPlayerIndex) ;
which throws an error because I cannot delete the default video player...
Can anyone help me out here and tell me what I am doing wrong?
Thanks!
--d
OnRoll Completion
I have small images (mc's) together.
When the curser goes across the images, I want them to fade in and fade out.
The code I am using for that part is below:
var depth = 0;
for (var i = 0; i < 10; ++i) {
this["image" + i].onRollOver = function() {
this.play();
};
this["image" + i].onRollOut = function() {
this.onEnterFrame = rewind;
};
}
function rewind() {
if (this._currentframe > 1) {
this.prevFrame();
} else {
delete this.onEnterFrame;
}
}
This is my question, is there a way for the mc to keep on playing, then rewind if the curser is only over it for a split second?
Thanks!
GotoAndStop Following Flv Completion
I've searched here and Google and found a lot...that doesn't work. Or I'm doing it wrong which is a definite possibility.
I'm intermediate Flash but brand new to AS3. I've been able to cod buttons and such but...
I can successfully built a custom flv player that streams and plays an flv.
What I can't do is gotoAndStop once it completes.
Any help?
Completion Button.
I'm building multiple questions quiz. How would I script the button so that when all questions are answered correctly, the word "Complete" will appear.
Course Completion Not Registering In LMS
A vendor had built courses for us a few years ago. There are 5 modules. The courses are SCORM and are tracked in the LMS from Learn.com.
We recently had 60 students sign up for a course, but they are not getting completion tracking for 4 of the 5 modules. The students are using IE7 and Flash Player 9.
Completion works for the module where the completion code is send from an HTML page. The completion does not work from any of the pages where the completion is sent from Flash. The flash files were coded with AS2, here is the code on the "Finish Button":
finishBtn.onPress = function()
{
import flash.external.ExternalInterface;
ExternalInterface.call("modCompCall");
trace (score);
trace (maxScore);
_root.finalScore = int((_root.score/_root.maxScore) * 100);
trace (finalScore+"final");
getURL("javascript:var value = mm_adl_API.LMSSetValue('cmi.core.lesson_status', 'completed')");
var mycall:String;
mycall = "javascript:var value = mm_adl_API.LMSSetValue('cmi.core.score.raw', '";
mycall = mycall.concat(finalScore);
mycall = mycall.concat("');");
getURL(mycall);
trace(mycall);
trace(finalScore);
}
Does anyone know if this problem is caused by the getURL function?
We do not know when this problem appeared as no one has registered for this course for over 2 years.
This is the code from the HTML page that works...
<input type="button" name="mm_finishBtn" value="Finish Lesson" onClick="modCompCall()">
and the supporting .js function:
function modCompCall() {
if (mm_adl_API != null){
// set status
mm_adl_API.LMSSetValue("cmi.core.lesson_status", "completed");
}
Thanks in advance for any ideas.
Text
Advance To Next Soundfile On Completion Of Another?
hi, I made a script that plays mp3's and shows the title in some dynamic text. After one song is done, I want it to automatically progress to the next one and update the dynamic text with the new title. How would I do this? Thanks for any help.
Here's what I have so far.
soundToPlay = new Sound();
title1= "testing - track1";
song1="track1.mp3";
title2= "nextsong - track1";
song2="track2.mp3";
text2.text = title1; //dynamic text
soundToPlay.loadSound(song1, true);
AS Movement - Detecting Completion?
I have a movie clip on the main timelinewhich moves smoothly to different _x and _y coords according to which button gets pressed. The movement is AS controlled, rather than tweened. I need to detect when the clip has arrived at the specified coords in order to activate a loadMovie action.
The movement is specified by the following script:
onClipEvent (enterFrame) {
Xsquare = _root.plan._x;
Xdiff = Xpos-Xsquare;
Xmove = Xdiff/3;
_root.plan._x = Xsquare+Xmove;
Ysquare = _root.plan._y;
Ydiff = Ypos-Ysquare;
Ymove = Ydiff/3;
_root.plan._y = Ysquare+Ymove;
updateAfterEvent(enterFrame);
}
For Loop Completion Listener?
Is there an event listener for a completed "for each" loop? or should I increment a variable each time round and add an if statement at the end of the for loop set to trigger my onComplete function after so many iterations?
Loading Website On FLV Completion
I just want to have an FLV intro movie load my main.htm when the flv is finished playing.
I am not to familiar with actionscript. My guess is an eventlistener.
What is the code that I put in.
Thanks
Ping Function Again After Completion
I'm running this function with a setInterval, but that's not working. Instead of pinging the function on a time base, I need it to start again after it has finished.
Code:
var items:Array = new Array("artExchange", "austinVentures","axcelis","broadCloud");
function switchimage(){
box.attachMovie(items[random(items.length)], "thang", 1);
box._alpha = 1;
box.Wait = 20;
box.onEnterFrame = function() {
if (box._alpha<100 && box.Wait>0) {
box._alpha += 5;
trace("Fade In "+box._alpha);
}
if (box._alpha>=100 && box.Wait>0) {
box.Wait--;
trace("Waiting "+box.Wait);
}
if (!box.Wait) {
box._alpha -= 5;
trace("Fade Out "+box._alpha);
}
if (!this.Wait && this._alpha<0) {
delete this.onEnterFrame;
trace("END");
}
}
};
timer = setInterval(switchimage, 0);
How can I make the function start again after it completes?
Firing An Function On Completion Of Another
Hello all!
quick and easy question, i'm sure:
i would like to fire a function upon the completion of another function, but i'm not sure how. what i want to do is add a TextField to a MovieClip after a tween has occurred on that MovieClip. would some sort of Event.COMPLETE listener be appropriate? can an event listener listen for the completion of a function? if so, how would i go about that? I'd post the code, but there's a bunch of extraneous stuff in there, so i don't want to distract from what I'm sure is a very simple question with a very simple answer. Any help would be greatly appreciated.
After Completion Of Current Function Run Next
Hi All,
I am attempting to run a particular function upon the completion of the another function. If anyone has any ideas it would be greatly appreciated!!
This is what I attempted but I believe this only works for movieclips.
==============================
slide_left();
slide_left.complete = function() {
slide_down();
};
--------------------------------------
or
--------------------------------------
slide_left();
if(slide_left = complete) {
slide_down();
};
==============================
neither seems to work, but its probably because these are intended for movieclips
developmental
Completion Of FLV - Video Object And FMS
I am creating a simple video player with the video object but I am using Flash Media Server.
I can not figure out how to determine the completion of the FLV. Can anyone help?
Here is my code:
Code:
var nc:NetConnection = new NetConnection();
nc.onStatus = function(info)
{
trace("#NC# " + info.code);
}
function init()
{
ns = new NetStream(nc);
vid.attachVideo(ns);
ns.OnStatus = function(info)
{
trace("#NS# " + info.code);
}
_root.loadCurrentCC("bunnel");
ns.play("Welcome");
}
play_btn.onPress = function () {
init();
play_btn.gotoAndPlay(2);
if (_root.pageFlipOn == true){
_root.pageFlipOn = false;
}else{
_root.pageFlipOn = true;
_root.loadCurrentCC("blank");
}trace(_root.pageFlipOn);
}
pause_btn.onPress = function () {
ns.pause();
}
var id:Number;
ff_btn.onPress = function():Void {
var dest1:Number = ns.time;
id = setInterval(function():Void {
ns.seek(dest1 += 2);
}, 100);
}
ff_btn.onRelease = function():Void {
clearInterval(id);
}
rw_btn.onPress = function():Void {
var dest:Number = ns.time;
id = setInterval(function():Void {
ns.seek(dest -= 2);
}, 100);
}
rw_btn.onRelease = function():Void {
clearInterval(id);
}
nc.connect("rtmp://wdmdfms-live.uwsp.edu/DESTREE_J/");
Completion Of FLV - Video Object And FMS
I am creating a simple video player with the video object but I am using Flash Media Server.
I can not figure out how to determine the completion of the FLV. Can anyone help?
Here is my code:
Code:
var nc:NetConnection = new NetConnection();
nc.onStatus = function(info)
{
trace("#NC# " + info.code);
}
function init()
{
ns = new NetStream(nc);
vid.attachVideo(ns);
ns.OnStatus = function(info)
{
trace("#NS# " + info.code);
}
_root.loadCurrentCC("bunnel");
ns.play("Welcome");
}
play_btn.onPress = function () {
init();
play_btn.gotoAndPlay(2);
if (_root.pageFlipOn == true){
_root.pageFlipOn = false;
}else{
_root.pageFlipOn = true;
_root.loadCurrentCC("blank");
}trace(_root.pageFlipOn);
}
pause_btn.onPress = function () {
ns.pause();
}
var id:Number;
ff_btn.onPress = function():Void {
var dest1:Number = ns.time;
id = setInterval(function():Void {
ns.seek(dest1 += 2);
}, 100);
}
ff_btn.onRelease = function():Void {
clearInterval(id);
}
rw_btn.onPress = function():Void {
var dest:Number = ns.time;
id = setInterval(function():Void {
ns.seek(dest -= 2);
}, 100);
}
rw_btn.onRelease = function():Void {
clearInterval(id);
}
nc.connect("rtmp://wdmdfms-live.uwsp.edu/DESTREE_J/");
Preloader After Project Completion
Hi
I have recently completed a free learning language program in flash, it works well and everything, but then being an amateur in flash, I forgot to make a preloader. Now, I know how to make a preloader, but how do I make space on the first frame on the timeline so that I can put the actionscript there? I tried selecting all the artwork, etc and moving them forward one frame, it doesn't work!! If I do that, the program doesn't work. Any suggestions will be highly appreciated.
Thanking All for their time.
Hide Video On Completion
Noob, trying to figure out how to hide a .flv and/or the movie clip it is contained in, after the video has played through completely . The .flv is loaded vis a vis Lee's tutorial on loading videos in AS 3.0.
I see in Flash Help that a NetStream object does have a "NetStream.Play.Complete" status event but it seems to want to attach that to an addEventListener via a 'client' object??? Do I ?access? the play.complete event info through NetStreamStatus? (Curious minds want to know!) (I kinda got the NetConnection and NetStream concepts, but working with NetStream in AS 3.0 has me confused.)
I just don't get it. Also, in the "NetStream.Play.Complete" statement, Play and Complete are capitalized in the help guide, but they only turn blue when play and complete are lower case. Again, confused. If someone could show me the code to hide the .flv and a brief explanation for how/why it works, I'd really appreciate it. Thanks, Eric.
Indicating Completion Of Movie Clip
how does Flash MX allow you to wait for a movieclip to finish playing before performing other activities? I have a movieclip I'd like to load after another has finished.
Loading A Page Upon Movie Completion
Having trouble in Flash 5 getting an image map to work, so what I want to do is have the movie play and upon completion of the movie it loads a new page. How can I do this?
Detecting The Completion Of Streamed Sound
Is there a way to detect if a streaming song has finished playing? I'm working on a little streaming web radio and everything seems to be working right but I have not figured out how to keep it playing through my entire array of songs. Please help! Thanks.
Code Completion For Elements In Array
Does anyone know how to activate code completion for elements in an Array. For example
var user:Object = new Object();
var myArray:Array = new Array();
myArray[0] = user;
myArray[0]. // no code completion here
It appears Flash has no idea what data type is in myArray[0], so code completion don't work.
Preloader Problems - Not Loading On Completion...
Hey,
I have a problem with my flash movie, it's not loading. I get the preloader and the bar goes along, but i think it gets to 99% or 100% and never loads.
Below is a screenshot of my scene1 - the actionscript layer is only to load a few html pages, the middle layer is the preloader - first frame script below...
onClipEvent (load)
{
total = _root.getBytesTotal();
}
onClipEvent (enterFrame)
{
loaded = _root.getBytesLoaded();
percent = int(loaded / total * 100);
text = percent + "%";
gotoAndStop(percent);
if (loaded == total)
{
_root.gotoAndPlay("s1");
} // end if
}
the lowest layer, second frame contains the main movie, but like I say it never loads on html ftp'd up to the site! It works on a preview and even html piped through on the pc, but as soon as it's up there it never hits s1.
Someone please help me!!!
Running A Function Upon Song Completion
I'm working on a project that plays random song tracks. Right now it just randomly plays a track and then stops. Is there any way for Flash to start the next song after one song completes.
Here is the script I have so far. BTW, a couple people on this forum helped me with this. They were a HUGE help with helping me understand how this works.
Code:
var songs:Array = new Array("music/track0.mp3", "music/track1.mp3", "music/track2.mp3", "music/track3.mp3", "music/track4.mp3", "music/track5.mp3", "music/track6.mp3", "music/track7.mp3", "music/track8.mp3", "music/track9.mp3", "music/track10.mp3", "music/track11.mp3");
var songPlayed:Array = new Array();
function randomSong() {
var randomNumber = random(songs.length);
var notinList = true;
for (i=0; i<songPlayed.length; i++) {
if (songPlayed[i] == randomNumber) {
notinList = false;
}
}
if (notinList) {
songPlayed.push(randomNumber);
playSong(randomNumber);
} else if (songPlayed.length == songs.length) {
songPlayed = new Array();
randomSong();
} else {
randomSong();
}
}
function playSong(randomNumber) {
track = new Sound();
track.loadSound(songs[randomNumber], true);
track.onSoundComplete = function() {
randomSong();
if (_root.soundOff_mc._currentframe=2) {
track.setVolume(0);
}
};
}
randomSong();
_visible = False Upon Tween Completion?
I have a movie clip on my stage with an On and Off button. Its on (visible) by default, and I'm using this code for my Off button which causes the movie clip to fade away:
Code:
import mx.transitions.Tween;
import mx.transitions.easing.*;
function pilotOff() {
var pilotOffAlphaTween:Tween = new Tween(_root.pilotmc, "_alpha", Regular.easeOut, 100, 0, 15, false);
}
I call the function when the button is pressed and it works fine.
My On button code is similar, only it fades in instead off:
Code:
function pilotOn() {
var pilotOnAlphaTween:Tween = new Tween(_root.pilotmc, "_alpha", Regular.easeOut, 0, 100, 15, false);
_root.pilotmc._visible = true;
}
Now notice my "_root.pilotmc._visible = true;" in the On function. I have that there because what I WANT to do is have the _visible property set to False when the Off button is pressed. However, I don't know how to do that because it would need to wait for the alpha of the Off animation to be 0 before setting it's visiblity to false, or else you'd never see the fade out animation.
Ideas?
On Completion Of Drawing A Loaded Image
im adding a loader as a child to a movieclip using the addchild function. the loader has preiousley loaded an image via the url. the movie clip has another child movieclip within it which contains a loading graphic. i want to delete or otherwise make invsible this graphic once the image has finished drawing.
how can i do this?
thanks
Check Tween Transition Completion
I was wondering. Is there some method of checking if a tween transition is complete?
Say I have this:
ActionScript Code:
new mx.transitions.Tween(my_mc, "_x",mx.transitions.easing.Regular.easeIn,my_mc._x,my_mc._x+100,2,true);
I usually check in some onEnterFrame handler if the transition has come to an end(by checking the start _x with the end _x). Then I call some function that is supposed to be launched when my transition is over.
Is there a fancier way of doing this?
Thanks guys
Stop All Aounds Upon Completion Of All Functions
Hi,
I am building something in Flash CS3 where each rollover of a movie clip launches a sound. I would like to stop all sounds once every clip has been rolled over, but I don't want to just use a stop all sounds actionscript that I assigned to a random button, assuming it would be the last rolled over.
Is there any actionscrip to stop all sounds once all functions I've written have been (collectively) completed?
Thanks for your help!
Edited: 10/07/2007 at 08:31:33 AM by GollyAlexandra
Check Loaded SWF Playback Completion
So, I'm not sure the best way to do this in AS3 and need guidance. I am loading an SWF into a holder clip, and it's a linear animation. When it's donw playing, I want to do something else. My research seems to indicate the best way is to count frames and compare with total frames. But my code is giving me 0 for currentFrame. What am I doing wrong?
Attach Code
// loader object
var the_loader:Loader = new Loader();
var current_animation = null;
// load the first clip
function load_animation():void {
the_loader.contentLoaderInfo.addEventListener( Event.COMPLETE, animation_loaded );
the_loader.load( new URLRequest( base_url + '/' + clips[current_clip].c_url ) );
}
function animation_loaded( evt:Event ):void {
// add the clip
current_animation = the_loader;
holder_clip.addChild( current_animation );
}
load_animation();
// timer object (for counting frames played)
var myTimer:Timer = new Timer(50);
myTimer.addEventListener(TimerEvent.TIMER, watch_animations);
myTimer.start();
// ALWAYS SHOWING ZERO FOR currentFrame
function watch_animations( event:TimerEvent ):void {
trace( 'current frame: ' + the_holder.currentFrame );
}
Failed To Attach To Completion Port
Hi, I just installed FMS2DeveloperEdition, left EVERYTHING set to default during instalation, my firewall is off, my FMS is running, when I ping Server 1 [localhost], I get 9ms success, but just when I logged to fms2_console, I got this message in server log:
Thu 02:36:30 PM: Core (5940) connection to admin accepted.
Thu 02:36:30 PM: Core (5940) sending register cmd to edge.
Thu 02:36:30 PM: Asynchronous I/O operation failed (Failed to attach to completion port: The parameter is incorrect. 87).
HEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEELP I'm starting to freak out and suddenly this thoughts - me, punching computer and throwing it out of window - are popping up in my head. help help help I need to see one tiny little thing working in FMS
MX 2004 Pro: Advancing Slides Upon FLV Completion
I'm trying to advance to the next slide in a presentation using the "NextSlide" behavior of the MediaDisplay playing the FLV. I can't use cues because I have that set to LabeledFrame navigation (the movie changes frames during it's duration, and slides only upon completion.) In the prvious frame, I have a next slide behavior on a MediaDisplay playing an mp3, this functions perfectly. By placing a trace in the on(complete) statement for the FLV display, I've found it is not sending out the complete call at all. Any thoughts on why?
Thanks,
Jeff Kirsch
Simple Action Upon Completion Of Loaded MC
hello-
i'm trying do what seems like it should be simple, yet i am struggling. on my main timeline frame 1 - i load in an external .swf created in after effects. i would like this swf to play all the way through, then upon completion advance the main timeline to frame 2. here's my AS on _root.frame 1 that seems to immediately advance to _root.frame 2. if i take out the onEnterFrame info, the MC loads in fine.
Code:
stop();
_root.holder.loadMovie("swfclip.swf");
_root.holder.onEnterFrame = function() {
// your statements here
if (_root.holder._currentframe==_root.holder._totalframes) {
trace("last frame");
_root.gotoAndStop(2);
}
}
thanks much in advance!
Event That Listens For Function Completion
Hi,
This is what is currently happening with my code:
I make a call to a function on the first frame of my main timeline. Within that function there are some event listeners that listen for a certain object to be ADDED_TO_STAGE. After that call to the function on the first frame of my main timeline, I make another call to another function. But I only want the second function to start once the certain object I mentioned from the first function has been ADDED_TO_STAGE. And no, I can't just put the second function call within the ADDED_TO_STAGE listener for reasons that would take too long to explain. So, basically, I need a way to stall the code on the main timeline from executing the second function call while the first function has not completely finished (including the call of the listener). I hope I explained this ok.
O and also, I don't want to just throw down a timer or something. I need it to be efficient. Let me know if there is a way that I can create an event that listens for function completion. Thanks
icekube12jr
MX 2004 Pro: Advancing Slides Upon FLV Completion
I'm trying to advance to the next slide in a presentation using the "NextSlide" behavior of the MediaDisplay playing the FLV. I can't use cues because I have that set to LabeledFrame navigation (the movie changes frames during it's duration, and slides only upon completion.) In the prvious frame, I have a next slide behavior on a MediaDisplay playing an mp3, this functions perfectly. By placing a trace in the on(complete) statement for the FLV display, I've found it is not sending out the complete call at all. Any thoughts on why?
Thanks,
Jeff Kirsch
Calling Functions On Completion Of Previous
Hi!
Please forgive my slowness with AS but how do you call a function after the previous has completed?
I have the following code:
Code:
import com.mosesSupposes.fuse.*;
ZigoEngine.register(Fuse, PennerEasing, FuseFMP);
FuseFMP.writeFilter(rh, "Blur", {blurX:50, blurY:50, quality:10});
var f:Fuse = new Fuse();
f.push({target:rh, Blur_blurX:0, Blur_blurY:0, seconds:1.5, ease:"easeInOutQuad"});
f.start();
var g:Fuse = new Fuse();
g.push({target:grad, x:500, seconds:2});
g.start();
But both functions are calling at the same time instead of g after f.
Also, on completion of g I want to have a 2 second pause before redirecting to an url (i.e this page will be a kind of splash screen before going to the main site). How would I do this?
Again, sorry for being such a bloody newbie!
Thanks for any help.
[F8] Switch Scenes After Completion Of Previous Scene
Hi guys,
ive been trying to do the following but with limited succes. I'm trying to tell a story that changes depending on what soundtrack is playing. Basicly there are 2 soundtracks to choose from, and when soundtrack 1 plays you see the scenes appropriate for that soundtrack, and when you switch soundtrack, you get the scenes for that specific soundtrack, but after the current scene is done.
so i tried to do this by adding the following piece of code after each specific scene (not that i mean scene as in a movie-scene, not a scene in flash )
Code:
if (_root.wichscene == "b"){
gotoAndPlay("sceneb3");
_root.aantalB = _root.aantalB + 1;
}
else{
gotoAndPlay("scenea3");
_root.aantalA = _root.aantalA + 1;
}
i determine the variable ofcourse by clicking the button that switches the soundtrack, but it doesnt seem to do anything. Even trying to trace something in both the if and the else statement doesnt seem to do anything. Any of you guys know what im doing wrong?
Thanks in advance
Trigger Action On COMPLETION Of Stage Resize?
So here's what I'm trying to do: When the user clicks on the corner of the browser and resizes the stage, I dont want the Resize actions to occur until the user RELEASES the mouse or until the resize is complete. So, as long as they're dragging the mouse around and resizing nothing would happen, but then as soon as the mouse as released it kicks in.
I tried:
this.stage.addEventListener( Event.RESIZE, stageResizer,false,0,true);
this.stage.addEventListener(MouseEvent.MOUSE_DOWN, stageMouseDownhandler);
this.stage.addEventListener(MouseEvent.MOUSE_UP, stageMouseUphandler);
But this didnt work because when you MOUSE_DOWN on the Browser rather than the Stage, it isnt detected by the stage. And I going to have use Javascript or something?
tia,
-z
Information On Code Completion Format/options
I'm looking for information on the code completion files for the Flash IDE. I have built these before - XML files that (somewhat) mimic the structure of the classes you are documenting - but am looking for any info on supported options and features.
The files I'm describing can be found in the ConfigurationActionsPanelActionScript_1_2CustomActions and ConfigurationActionsPanelActionScript_3 folders.
I've thus far been able to hack stuff together based on existing files, but any information or documentation on the format/options for these files would help a great deal.
TIA,
Derek Vadneau
Calling A .js File Upon Completion Of Flash Video
I have a challenge whose solution has avoided us. Maybe you can help.
I’ll try to be succinct so as to not take up too much of anyone's time.
1. I’m using CS3, but ActionScript2 for videos we have uploaded to our website.
2. We are using AS2 because we want to target FlashPlayer 7
3. We want our entire video to play before the “Next” button on our html page is enabled
4. Could you, would you, send to me the AS code that would enable the flash video file to communicate with our .js script
5. And if you could do that, please also indicate where and how it is inserted into the flash application?
6. I’m fairly new at flash and we are having an unsuccessful time at having the AS2 code talk to our .js code.
It would be very much appreciated.
m.behr@lawroom.com
Determine Size Of JPG Prior To Load Completion
is it possible to determine the size of a jpg you are loading into flash before its finished loading?
ive seen sites where an image area resizes itself before displaying a new photo. anybody do this before?
i know that technically i could save my images as swfs and include size info in frame 1 of the movie, or something like that. but id rather deal with plain jpgs if i could.
ideas?
thanks!
Making FLV Movie Disapear(close) Upon Completion?
Hello there!
Have problem for that I just can´t find a solution anwhere...(Googling for about 4+h for sure...)
Here is what I would like to do:
Create an Flash-movie site, Load an FLV movie (Steam or paked-in-SWF doesn´t matter) in the way that after the movie has been loaded and seen (comes to end of it) the movie should disapear and "flash page" continues... So that FLV movie would act as an Flash page INTRO ONLY! How can I do that?
Thx for help in advance!
T.B.
Berlin
P.S. I know I could just convert FLV to a SWf and than import, but that is not the option because of Sound issues in Imported FLV files, just spoilis the whole movie...
Need XML Actionscript Menu Fixed, Will Pay $50 In PayPal For Completion (simple Fix)
My actionscript friend bailed out on me and left me with this partially working .fla XML menu. I need this completed and I have a feeling it shouldn't take long. (The actionscript is completed - it's buggy, needs tweaking)
To verify completion I will need the user to display a working menu based on the XML file I provide and give FTP access to their server to edit XML file so I know the menu works. I'll pay half for the working display and the other half on delivery.
Contact me for the .fla, ps mockup of working prototype and single XML file that feeds the menu.
The first who can provide this menu will be awarded the $50 only. I will contact everyone when I have the fix.
It should be very little work and I expect it will only take 30min of an experts time.
rob@codesilence.com
Thanks, Rob
508.527.1731
[MX04] Load External Images, Fade In On Completion.
Code:
loadee = new MovieClipLoader();
ImageHolder._visible = false;
loadee.load(bgfilename, ImageHolder);
templistener = new Object();
templistener.onLoadComplete = function() {
ImageHolder._alpha = 0;
ImageHolder._visible = true;
};
loadee.addListener(templistener);
And back at the ImageHolder movie clip (a movie clip on stage at the lowest level filled with a shape of transparent fill color)
Code:
onClipEvent (enterFrame) {
if (ImageHolder._alpha < 100 && ImageHolder._visible == true) {
ImageHolder._alpha += 10;
} else {
ImageHolder._alpha = 100;
}
}
And.. no image is shown... Probably a simple syntax error, but I'm not seeing it, and flash says its ok.
Flash 8 Quiz Guru Needed: Make Link Appear For Next Test Only If Test Taker Passes.
Greeings, all,
Flash 8 has quiz templates which are coded for multiple choice, true/false, text statement, and matching types of questions, along with hotspots and probably anoher type I am forgetting. The test taker makes their selection(s) or answers, and clicks a "check answer" button. They then get a feedback statements depending on whether they have answered correctly or not. Many questions involve multiple selections to be correct, but all must click on the "check answer" button to advance to the next question.
The point is that all of this functionality is coded in the component(s) which make the template so versatile. A copy of my .fla shouldn't actually be needed (I am guessing here), because the component code is what I believe needs tweaking, at least the part where the final percentage of correct answers is calculated at the end of the test, and that percentage is compared to a user-defined passing percentage score.
I think this requires a Flash Quiz Guru, who knows just how to connect the pass or fail result to a new button or a "go to" redirect. I don't know whether the same effect could be accomplished by frame scripting, but I expect tweaking the component(s) code would seem a more direct approach.
I cannot fill in the blanks for any idea that is just an idea. If anyone can code this, make it work and test it, and direct me to where the snippets must be placed, I would be deeply grateful. This is about education, not a game or commercial razz-ma-tazz.
Are there any Flash Quiz Guru's who can help me out with this?
Thank you.
regards,
stevenjs
____________________________________
"I am but an egg."
--Stranger in a Strange Land
Flash Quiz Guru Needed: Make Link Appear For Next Test Only If Test Taker Passes.
Greeings, all,
Flash 8 has quiz templates which are coded for multiple choice, true/false, text statement, and matching types of questions, along with hotspots and probably anoher type I am forgetting. The test taker makes their selection(s) or answers, and clicks a "check answer" button. They then get a feedback statements depending on whether they have answered correctly or not. Many questions involve multiple selections to be correct, but all must click on the "check answer" button to advance to the next question.
The point is that all of this functionality is coded in the component(s) which make the template so versatile. A copy of my .fla shouldn't actually be needed (I am guessing here), because the component code is what I believe needs tweaking, at least the part where the final percentage of correct answers is calculated at the end of the test, and that percentage is compared to a user-defined passing percentage score.
I think this requires a Flash Quiz Guru, who knows just how to connect the pass or fail result to a new button or a "go to" redirect. I don't know whether the same effect could be accomplished by frame scripting, but I expect tweaking the component(s) code would seem a more direct approach.
I cannot fill in the blanks for any idea that is just an idea. If anyone can code this, make it work and test it, and direct me to where the snippets must be placed, I would be deeply grateful. This is about education, not a game or commercial razz-ma-tazz.
Are there any Flash Quiz Guru's who can help me out with this?
Thank you.
regards,
stevenjs
____________________________________
"I am but an egg."
--Stranger in a Strange Land
Flash Quiz Guru Needed: Make Link Appear For Next Test Only If Test Taker Passes.
Greeings, all,
Flash 8 has quiz templates which are coded for multiple choice, true/false, text statement, and matching types of questions, along with hotspots and probably anoher type I am forgetting. The test taker makes their selection(s) or answers, and clicks a "check answer" button. They then get a feedback statements depending on whether they have answered correctly or not. Many questions involve multiple selections to be correct, but all must click on the "check answer" button to advance to the next question.
The point is that all of this functionality is coded in the component(s) which make the template so versatile. A copy of my .fla shouldn't actually be needed (I am guessing here), because the component code is what I believe needs tweaking, at least the part where the final percentage of correct answers is calculated at the end of the test, and that percentage is compared to a user-defined passing percentage score.
I think this requires a Flash Quiz Guru, who knows just how to connect the pass or fail result to a new button or a "go to" redirect. I don't know whether the same effect could be accomplished by frame scripting, but I expect tweaking the component(s) code would seem a more direct approach.
I cannot fill in the blanks for any idea that is just an idea. If anyone can code this, make it work and test it, and direct me to where the snippets must be placed, I would be deeply grateful. This is about education, not a game or commercial razz-ma-tazz.
Are there any Flash Quiz Guru's who can help me out with this?
Thank you.
regards,
stevenjs
____________________________________
"I am but an egg."
--Stranger in a Strange Land
Change Swf File Dimension Size AFTER Completion Of Build/design?
Sigh. Alright, I'm CROSSING my fingers here, but I think I know what the answer is going to be. Sniff sniff!
I've COMPLETED the building of my swf file, and for some idiotic reason I made the stage (hence file dimensions, correct?) dimensions something like 1100x718. I use 1440x900 as the resolution on my computer, I think it looks so much better; but I should have known the norm was WAY bigger than that, I think it's SOMETHING like 700x400 or such (run with me here, I forget the actual "acceptable web page design dimensions for the general masses.")
SO, IS it possible to SIMPLY change something/the resolution dimensions in Flash, WITHOUT it cropping my fla/swf file (sort of the difference between Canvas and Image cropping in Photoshop. I want to reduce my canvas/stage down, not crop it like Image would do. Make sense?) so that my website is more readily "readable" without alot of scrolling by the 700x400 crowd (I've read about scaling using code, but that causes distortion, correct?) or am I just sort of screwed and IF I wanted to do this, would just have to redesign the entire thing.
Thanks for the help!
Do Flahs Movie Files Automatically Fire An Event A Completion?
Hi everyone,
I have very little experience in Flash. I progam in c++ and am trying to write a little program that can play flash files.
I need to know when a flash move has ended.
Is there any way i can check for this or do the movie files fire an event when they are finished.
Thanks,
Jai
(Authoring Mode-test Scene-test Movie )Different Results WHY?
(Authoring mode-test scene-test movie )Different results WHY?I will get mad working on a quiz for a month plz help: im working on quiz game -frame by frame- its 15 scenes each scene contain about 70 frames with 70 action script :go to and stop - go to and play - stop every thing is fine till scene No. 11 in the authoring mode when choose from control menue enable simple buttons - enable simple frame action : its working fine scripts executed fine but when going to test movie mode some scripts doesnt work WHY? what mistakes i have done? what should i do ? how can a void such a problem ? any suggestions PLZ??? Thanks in advanced
Buttons Work In Test Scene But Not In Test Movie...WHY?
Hi all,
I have buttons in a movieclip i've used
_root.
and the buttons work when i do test scene but when i try and test movie the buttons link back to the wrong screen. why is this? There is no apparent reason as the scripting seems fine.
|