# Countdown MM:SS Timer?

**URL:** <https://forum.kirupa.com/t/countdown-mm-ss-timer/302663>\
**Category:** flash\
**Created:** [January 5, 2010, 10:14am UTC](https://forum.kirupa.com/t/countdown-mm-ss-timer/302663 "2010-01-05T10:14:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![grandpaw\_broon](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/grandpaw_broon/32/3985_2.png) [@grandpaw\_broon](https://forum.kirupa.com/u/grandpaw_broon)\
**Post date:** [January 5, 2010, 10:14am UTC](https://forum.kirupa.com/t/countdown-mm-ss-timer/302663/1 "2010-01-05T10:14:03Z")

</div>

Hi everyone.

Im useless with time.

I need to create a timer for something which i can display, lets say 2 minutes which is refreshed each second until it reaches 0.

02:00  
00:00

If i was displaying seconds, something like this would be fine:

```auto
var time:int = 120;

var t:Timer = new Timer(1000);
t.addEventListevener(TimerEvent.Timer, onTimer);
t.start();

function onTimer(e:TimerEvent): void
{
     time--;

      if (time == 0)
      {
         //do something
         //remove listener
       }
}

```

But i just cant do this type of thing with minutes, how to get 01:43 for example just blows my mind.

Any advice would be praised 😛
