• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

How to modify the code to get started the timer on mentioned time?

New Here ,
Apr 12, 2012 Apr 12, 2012

Copy link to clipboard

Copied

Hi,

I have the following code from a source. I would like to make a few changes as mentioned below:

First ....

1) The as3 code should get the time form "startMeeting_txt.text"

2) Compare it with current time from "currentTime_txt.text"

3) The Timer should be activated as soon as the "startMeeting_txt.text" = "currentTime_txt.text" and starts counting

4) When the "finishMeeting_txt.text" = "currentTime_txt.text" then

5) "message_txt.text" = "Meeting time is over"

How to modify the following code:

var count:Number = 60;

var myTimer:Timer = new Timer(1000,count);

myTimer.addEventListener(TimerEvent.TIMER, countdown);

myTimer.start();

function countdown(event:TimerEvent):void {

myText_txt.text = String((count)-myTimer.currentCount);

}

if(myText_txt.text == "0"){

      gotoAndStop(2)

}

Thanks.

TOPICS
ActionScript

Views

432

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 12, 2012 Apr 12, 2012

Copy link to clipboard

Copied

You should show an attempt to do this yourself so that your wishlist of what happens when makes better sense.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 12, 2012 Apr 12, 2012

Copy link to clipboard

Copied

LATEST

Thanks. I am at work now and don't have Flash installed on my PC. I will try it at home. I just found this code on a website and wanted to know it more without any try. I must try it first then seek help. I am sorry.

I do respect your advise.

Regards.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines