Cue point event to display text link in movie

HI -- This may be a fairly mundane question but I am having a
hard time figuring it out. I have a movie with several cue point
events. I would like a text link to be added to the right of the
movie when a certain cue point is hit. I would like the link to
stay in place and each time a new cue point is hit, a new link is
added below the last link.
I am stuck and can't seem to get this to work. Having a hard
time figuring out the action script. Any suggestions? I have
already followed the macromedia tutorials on this subject and am
just floundering.
thanks!

Since you are storing the number as an 'int' and then converting that int to a String for display, then you shouldn't expect 0's to be added on if the number is currently 0:
1) curnum = 0
2) 0 key is pressed
3) curnum = curnum * 10 + 0 = 0 * 10 + 0 = 0
A real calculator wouldn't keep appending 0's... at least, not a simple calculator comparable to the one you are writing. If you want to append 0's, try this:
- Keep a count of the number of 0's pressed.
- If curnum is changed to 0 (by pressing clear, for example, or turning on the calculator), reset the zero count to 1.
- Each time the '0' key is pressed, if curnum is 0, then increment the '0' count.
- When you update your display, use the following logic: if curnum is 0, then display the number of 0's specified in the zero count, otherwise just display the value of curnum.
Jason

Similar Messages

  • Using cue points to change a text box

    Ok I asked a simlar question before but I am still having trouble getting it to work.
    I have a video with 11 Cue points and at each cuepint I want the Typebox to change it text at each cue point.
    When the video is playing I want a the textbox to change the text when cue point 1 is reached. This is the code I am using. But every always goes straight to the whatever the last functions text and skips all the other before it. Its bassically this code repeated with difffernt function name and string.
    import fl.video.MetadataEvent;
    flvplayer.addEventListener(MetadataEvent.CUE_POINT,section2Cue);
    function section2Cue(event:MetadataEvent):void{
        for(var String = "section2" in event.info){
            typebox.text = "Hello";                        }
    So basically I want to tell flash, when CuePoint1 is reached text = "hello world" and when CuePoint2 is reached I want the text ="Hello Again". I don't know what I am doing wrong or what is the best way to tell flash how to do this

    Ok, I tryed that code Basically I want to call upon each cue point individually and have an event for each one. So how i tell it to display this only when Cuepoint1 is reach and display that only when Cuepoint2 is reached.  What data would help ?
    Most of my code is just buttons to reach each cuepoint within the video. I got that to work fine.
    I'll supply it anyways
    import flash.events.MouseEvent;
    // Assign a new skin to my FLVPlayback instance using ActionScript
    flvplayer.skin = "player.swf";
    flvplayer.fullScreenTakeOver = false;
    //select section menu button
    selectBtn.addEventListener(MouseEvent.CLICK, openMenu);
              function openMenu(event:MouseEvent): void{
                        trace("working");
                        selectMenu.gotoAndPlay(2);
              selectMenu.closeX.addEventListener(MouseEvent.CLICK, closeMenu);
                        function closeMenu(event:MouseEvent): void{
                                  trace("closing");
                                  selectMenu.gotoAndPlay(11);
              //Cuepoint Buttons
    selectMenu.sec1.addEventListener(MouseEvent.CLICK, section1Button);
    function section1Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section1");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Orion Health EMR Lite Overview";
    selectMenu.sec2.addEventListener(MouseEvent.CLICK, section2Button);
    function section2Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section2");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Adopt Electrionic Patients Records Easily";
              selectMenu.sec3.addEventListener(MouseEvent.CLICK, section3Button);
    function section3Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section3");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Introducing Orion Health EMR Lite";
                        selectMenu.sec4.addEventListener(MouseEvent.CLICK, section4Button);
    function section4Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section4");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Meet Mr. Smith - Patient Registration and Intake";
    selectMenu.sec5.addEventListener(MouseEvent.CLICK, section5Button);
    function section5Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section5");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Orion Health EMR Lite in the Exam Room - Clicnical Documentation and Orion Health HIE Integration";
    selectMenu.sec6.addEventListener(MouseEvent.CLICK, section6Button);
    function section6Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section6");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Working with Orion Health EMR Lite - Documentation";
    selectMenu.sec7.addEventListener(MouseEvent.CLICK, section7Button);
    function section7Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section7");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Order Entry in Orion Health EMR Lite";
    selectMenu.sec8.addEventListener(MouseEvent.CLICK, section8Button);
    function section8Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section8");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "ePrescribing";
    selectMenu.sec9.addEventListener(MouseEvent.CLICK, section9Button);
    function section9Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section9");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "ePrescribing";
    selectMenu.sec10.addEventListener(MouseEvent.CLICK, section10Button);
    function section10Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section10");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Quality and Utilization Reporting";
    selectMenu.sec11.addEventListener(MouseEvent.CLICK, section11Button);
    function section11Button(event:MouseEvent):void
              // Replace video_instance_name with the instance name of the video component.
              // Replace "Cue Point 1" with the name of the cue point to seek to.
              var cuePointInstance:Object = flvplayer.findCuePoint("section11");
               flvplayer.seek(cuePointInstance.time);
               typebox.text = "Summary";
    As for data? This is all I know about my CuePoints
    Would the best way to acheive changing type is to change the way my movie clips are set up? Instead of telling it within the actionscript maybe telling it to go to next frame within a movieclip with the content? I don't know exactly how to word what I am trying to acheive but I'm trying!
    thanks!

  • Video cue point events, or similar?

    Hi,
    In flex, the video GUI control has something called "cue points" -- you can get event callbacks when video playback hits time points of your choosing. This allows you to synchronize the video with other parts of your GUI. Is there something in JavaFX that allows the same thing? If not, are there plans to have it? When?
    thanks,
    Rob

    You don't even need a cuepoint to do this.
    Using the FLVComponent or the VideoPlayer object, use the
    "complete" event to execute code. You set up an event listener
    object to listen to the video object (using
    videoobject.addEventListener(listenerObject) ), and create a
    function for the listener object to do when the "complete" event
    occurs (such as listenerObject.complete = function() { do whatever
    Here's a link to a useful pdf about the VideoPlayer object.
    http://download.macromedia.com/pub/documentation/en/flash/fl8/VideoPlayer.pdf

  • Cue point to jump to next frame of movie

    Hi. I'm a bit lost assigning an action script created
    CuePoint (Entered in Paramenters Window for FLV media component) to
    tell my SWF movie to advance to the next frame and thus call the
    next video I want to throw onto that next keyframe.
    I know this must be basics to most, but somewhere I'm
    missing it. Once a CuePoint is created, how do I link that to
    trigger an action?

    Thanks for reply. I was out of things for a week with flu.
    Serious flu. Now I have to catch up. Grrrr.
    Does that mean ("cuePoint" , ... needs to be replaced with
    the actual name of the cue point to work?
    + The Cue point Parameters. What should they be set
    as?

  • How do I display Text linked to a dropdown list selection in a form?

    Ok, I have a form that has a dropdown list with several selections. What I want to have happen is when someone selects one of the options from the dropdown, I want to have text displayed to the right of that information that pertains to that selection.
    I have attached the page with the form I have created as well as the css document that is used.
    Any insight would be most appriciated! Thanks in advance!

    Hi,
    I browsed for you a bit and found this: http://javascript.internet.com/forms/suggest-messages.html Looks like what you need!
    Otherwise just search this database: http://javascript.internet.com/forms/

  • Handling Flash video cue points in Javascript

    Can any kind person give me any pointers on how to get Javascript in an HTML page containing an FLV video to listen for cue points in the video? I understand how to get the cue points in, but most people only seem to want to handle the cue point events within Flash. I want to use Javascript to display a different text in a page element at each point. Does the method vary depending on what player you're using? How about when it's the standard Flash playback component? Does there need to be any special Actionscript in the SWF containing the FLV?
    Thanks
    Fred

    Thanks Rob, will do.
    For anyone else looking into this issue there are some links to the ActionScript documentation on this StackOverflow post and an explanation of how to use ExternalInterface halfway down the page in this Adobe Devnet tutorial.
    Presumably you'd first import the ExtenalInterface class into your Flash with
    import flash.external.*;
    And then add an ActionScript event listener which sends the ID of each cue point out to the Javascript using the ExternalInterface.call() method:
    ExternalInterface.call(methodName:String, [parameter1:Object])

  • End of FLV advance? Cue points

    Hi there.
    Have been playing around with cue points in MX2004pro to get
    my swf movie to advance once the FLV that it loaded was at its end.
    However, MX2004pro gets really confused if you use the display
    component in instances in different scenes to call different videos
    with their own cue points. (you can delete them and then they just
    always exist when you're on the component again. No reference to
    the 2nd and 3rd component's action script for cue points in script
    editor etc.) Only got the first one to work and its cue points work
    fine, but the others are hopeless. Is there any other way to
    advance & play the timeline once a FLV reached its end apart
    from cue points?

    >>Is there any other way to advance & play the
    timeline once a FLV
    reached its end apart from cue points?
    Yes, you can use the onStatus event of the NetStream object
    to know when
    play has stopped.
    Dave

  • Cue Point Navigation

    I will preface this all by saying I am very new to the whole
    idea of using code for anything (I have problems programming my
    watering system at home and it's got buttons) and I could sure use
    some help from people in the know.
    I'm working on an FLA that has 7 talking head videos
    w/PowerPoint slides as pngs from a medical conference.
    I'm trying to get slides to synchronize with embedded
    navigation cue points in the video. All the code I entered so far
    was based on the Adobe article "Controlling Flash video with
    FLVPlayback programming-Cue point event handling" and I used the
    code example provided. When I exported the movie all I get is a
    flickering flv icon on the screen and the following error message:
    line 1 1046: Type was not found or was not a compile-time
    constant: MetadataEvent.
    Attach Code
    function cuePointHandler(event:MetadataEvent):void
    trace("name = "+event.info.name);
    trace("time = "+event.info.time);
    // Go to a frame label with the cue point name
    gotoAndStop(event.info.name);
    flvControl.addEventListener(MetadataEvent.CUE_POINT,
    cuePointHandler)

    before the function add the following line:
    import fl.video.MetadataEvent;

  • Cue Points and RTMPE

    I'm hosting an FLV (with embedded event cue points) using
    Flash media server 3.5 in the vod directory. While using Flash 9,
    within component inspector, if I use rtmp protocol in contentPath,
    I can populate the cue points information in the cuePoints section.
    If I use rtmpe, I get failed to load FLV. I've tried using CS4 and
    could not retreive cue points at all. Any help would be
    appreciated.

    I found that captions do reset from the starting point when I
    press reply but cue points (events) don't.

  • Using cue points to trigger events on the main timeline...

    Hi--
    I have successfully placed an flv (video) file (progressive
    download) on the main timeline of my movie with controls to play
    and pause (Flash 8 Professional). So far, so good!
    NOW TWO PROBLEMS: Does anyone know how to set it up so that
    when a specific cue point is reached in the video, it triggers an
    action on the main timeline? In this case, once the video is over,
    I want the main timeline to gotoAndPlay frame 3. Specific script to
    do this would be great!
    The other action I'd like to happen is that when the video
    begins, it targets a scrolling text mc ("text") in the main
    timeline and tells it to gotoAndPlay frame 2.
    Any advice would be GREATLY appreciated!!! Many
    thanks!!!

    I usually start off solving problems with the livedocs, as I
    recommend for anyone. The following link will take you to the
    NetStream.onCuePoint handler. This is what you need.
    http://livedocs.macromedia.com/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context= LiveDocs_Parts&file=00002561.html
    You can have this code on the main timeline. When the
    cuepoint is hit, it will invoke this event handler and inside is
    where your gotoAndPlay( ) should go.
    Your other question about the text will get activated by the
    same handler. Just have a conditional statement (if, switch, etc.)
    to differentiate between the two events. The text itself can be
    mask inside a movieclip.
    Does this help?

  • I need help with my event-based cue points with audio

    Im having trouble with my video game project for my action script 3 class at school. Here is what i did, i made a game called Tailgate toss up. I filmed my character and rendered it in Adobe Premiere. I than brought my .mov file into After Effects and I put event-based cue points-
    my first cue point at 0:00:03:13 called "loop"
    my second cue point at 00:00:03:27 called "draw"
    my third cue point at 00:00:05:24 called "bang"
    my fourth cue point at 00:00:13:29 called "dead"
    my fifth cue point at 00:00:14:29 called "You Lose"
    my last cue point at 00:00:19:14 called "End"
    Here is my action script 3 code
    ///first frame:
    start_btn.addEventListener(MouseEvent.CLICK, startGame);
    function startGame(event:MouseEvent){
    gotoAndStop(2);
    SoundMixer.stopAll()
    stop();
    ///second frame:
    stop();
    var loopTime
    var hitHim:Boolean = false;
    var vConnection:NetConnection = new NetConnection();
    vConnection.connect(null);
    var vStream:NetStream = new NetStream(vConnection);
    var client:Object = new Object();
    client.onCuePoint = onCuePoint;
    vStream.client = client;
    var myVideo:Video = new Video(418, 480);
    myVideo.y = 0;  ///this adjusts where the video is, right now it is the size of the canvas which is 418,480
    addChild(myVideo);
    myVideo.attachNetStream(vStream);
    vStream.play("michelle.flv");
    var throw_bottle:Sound
    throw_bottle = new Sound(new URLRequest("audio/throw_bottle.mp3")); //change to button noise, will add sound into ae file
    target_mc.addEventListener(MouseEvent.CLICK, shoot);
    target_mc.buttonMode = true;
    target_mc.visible = false;
    draw_mc.visible = false;
    function onCuePoint(cuePoint:Object):void {
       if(cuePoint.name == "loop"){
    loopTime = cuePoint.time;
        if(cuePoint.name == "draw"){
    var randomLoop:Number = Math.random()*10;
    if(randomLoop > 2){
    vStream.seek(loopTime);
    }else{
    setChildIndex(target_mc, numChildren - 1);  
    setChildIndex(draw_mc, numChildren - 1);    
    target_mc.visible = true;
    draw_mc.visible = true;
    if(cuePoint.time == "5:24"){
    draw_mc.visible = false;
    target_mc.visible = false;
    if(!hitHim){
    vStream.seek(15);    
    if(cuePoint.name == "dead"){
    vStream.close();
    myVideo.clear();
    gotoAndStop(3);
    if(cuePoint.name == "end"){
    gotoAndStop(3);
    function shoot(event:MouseEvent){
    throw_bottle.play();
    hitHim = true;
    ///my third and last frame
    playAgain_btn.addEventListener(MouseEvent.CLICK, playAgain);
    function playAgain(event:MouseEvent){
    gotoAndStop(2);
    SoundMixer.stopAll()
    stop();
    When I have no audio it works perfectly, no problems. When I bring audio in i re-render it as a .mov file and bring it back into After Effects and add the cue points to it. Than i re-render it out again as a flv file. When i bring it into my flash project it will work when the looping variable does just one loop and my target will appear so you can click on it or not. But when the looping variable makes it loop 2 to 10 times it skips over the catching (the part of the clip if you clip the button) and goes directly to the dropping of the can, not giving you the option of clicking the button. So basically it skips the "draw" or second cue point of my game and goes to "You Lose" cue point.
    Any suggestions?

    Hi,
    The latest audio driver for your machine is on the following link.
    http://ftp.hp.com/pub/softpaq/sp59501-60000/sp59649.exe
    Regards,
    DP-K
    ****Click the White thumb to say thanks****
    ****Please mark Accept As Solution if it solves your problem****
    ****I don't work for HP****
    Microsoft MVP - Windows Experience

  • HTML link to FLV cue point

    I am reasonably new to Flash and would like to know if I can
    create a html link to a cue point in a flash video file or to a
    particular frame in a normal swf file. If so, what is the correct
    syntax?

    Ok, I seemed to have succesfully linked to the cuepoints
    using, for example, the code below.
    [CODE]
    programsa.addEventListener(MouseEvent.CLICK,programsaClick);
    function programsaClick(event:MouseEvent):void {
    movie1.seekToNavCuePoint("Programs");
    [/CODE]
    However, now I have another issue. The FLV is on frame 2 and
    I want to navigate to it using buttons on frame 1. However when I
    try the following:
    [CODE]
    programsa.addEventListener(MouseEvent.CLICK,programsaClick);
    function programsaClick(event:MouseEvent):void {
    gotoAndStop("movie");
    movie1.seekToNavCuePoint("Programs");
    [/CODE]
    I get the error:
    TypeError: Error #1009: Cannot access a property or method of
    a null object reference.
    at videobig_fla::MainTimeline/programsClick()
    So, how can I tell a button to go to a cuepoint for a movie
    that's on a different frame?

  • Displaying previous FLV cue point during scrubbing

    I have a single FLV that has 10 different scenes in it. I've
    been able to make a "credit" list for each scene by adding
    actionscript cue points in the FLV component, and displaying the
    info using dynamic text. It all works fine.
    Now I want the dynamic text to reflect the current scene when
    the end user scrubs through the video using the seek bar. (Or at
    least after the seek bar is released and the FLV begins to play
    again.)
    I just need a head start, I think.
    Thanks for listening!
    David

    Thank you again Dima!!!
    Now I've CS6 now but the only way that I see to have flv is: Creates (I'm translating from my language) => Flash, from menu file.
    I need to insert cue point ("navigation" like in Media Encore Cs5.5).
    But the only marker that I see in CS6 is named "Chapter" (translating form my language).
    If I create an flv file (like above) I obtain two different flv files (one for chapter).
    Is there a way to insert inside the flv file the "navigation" cue points?
    Thank you again Dima.

  • Using event cue points to add buttons

    How do I go about having buttons display in an external flv file?  I know I can establish event cue points with Adobe media encoder.  I want the the buttons and graphics to appear and stay on the screen, even though the external flv loops.  Its been a long day and I have exhausted all other options, otherwise I would not have asked on here.  Thanks in advance.  Oh btw using Flash cs 5.5 and as 3.  thanks

    i just added x and y locations:
    Movie01.addEventListener(MetadataEvent.CUE_POINT,cuepointF);
    function cuepointF(e:MetadataEvent):void{
    trace(e.info.name);  // this will display your cuepoints when their dispatched.  you'll use if-statements below this line to add your buttons.  eg,
    if(e.info.name=="middle"){
    addChild(button1);  // assuming button1 is already created.
    button1.x=639;
    button1.y=140.5;
    it worked with no errors
    thanks again! 

  • How to display many Links like text with multi lines?

    I need to:
    1)display many links in one container like text
    2)each link have onClick event Handler
    Example:
    Link1 SomeLink2 Link3 \*
    Link4 AnatherLink5            \*
    AndOneMoreLink6              \*
    \* - right border of container
    i'v tried TileGroup, but it has colums.... Group - overlapped links in one place.... and so on.
    Any ideas how to do it?

    I think you overlooked some of the possibilities provided by Apex.
    For instance you can create a simple HTML region where you put the links as you prefer (makes sense if they are a fixed number and you need a special formatting).
    You can also create Lists (see shared components). Lists are specifically meant for links, like Task lists in the Apex Builder itself, but you cannot build them dynamically, so you must know in advance each and every static link.
    Or you can create a report if links come as result of a query which is good for building them dynamically.
    A fourth option is a PL/SQL region outputting HTP calls where you have total control over every aspect.
    Flavio
    http://oraclequirks.blogspot.com

Maybe you are looking for

  • My Windows (version 7 Pro, 64-bit) Media player will not play any of my stored music.

    IT JUST STARTED PLAYING AGAIN...ONE OTHER REASON I HATE WINDOWS 7!!!!!!  It is up-to-date (ver 12) and when I test the speakers, I get the test sounds OK but, when I try to play any of my stored music (and I have vocals and instrumentals) no sound is

  • CI issues on Linux - CentOS + Hudson

    Hi there, I got some issues to generate the Junit reports, it gets up to "Waiting for client connection" then do nothing for a few seconds. When it gets back this is what I get in the console: runUnitTests:      [java] Loading configuration file /opt

  • Simple XML question

    org.xml.sax.SAXParseException: The markup in the document following the root element must be well-formed. at org.apache.xerces.parsers.DOMParser.parse(DOMParser.java:235) at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:20

  • Using Java mail API from JSPDynPage

    Hi Experts, I am working on a Portal Assignment that requiresto sent work flow mails on the basis of error conditions. Can u please suggest if at all I can use Java Mail APIs from JSP page within the JSP DYN Page Framework. If at all Java Mail can be

  • 10.5.7 STILL NO LUMIX G1 RAW SUPPORT

    Apple how many times am I going to tell you to add RAW support for Lumix G1