# Pausing

**URL:** <https://forum.kirupa.com/t/pausing/12480>\
**Category:** flash\
**Created:** [January 31, 2003, 7:01pm UTC](https://forum.kirupa.com/t/pausing/12480 "2003-01-31T19:01:56Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![zkac050](https://avatars.discourse-cdn.com/v4/letter/z/b2d939/32.png) [@zkac050](https://forum.kirupa.com/u/zkac050)\
**Post date:** [January 31, 2003, 7:01pm UTC](https://forum.kirupa.com/t/pausing/12480/1 "2003-01-31T19:01:56Z")

</div>

Is there any way to create pausing functions, so that, code is only executed in steps for user interraction.  
For example:- The ability to run a search algorithm where there is a pause of one second between each displayed comparison of a letter, or everytime the user clicka abutton, one line of code is run.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 1, 2003, 5:44am UTC](https://forum.kirupa.com/t/pausing/12480/2 "2003-02-01T05:44:32Z")

</div>

Ther is I have seen it before

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 1, 2003, 7:18am UTC](https://forum.kirupa.com/t/pausing/12480/3 "2003-02-01T07:18:52Z")

</div>

er, maybe I’m not fully understanding your desire…but couldn’t you just have many keyframes with only one line of code on each frame ???

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [February 1, 2003, 5:12pm UTC](https://forum.kirupa.com/t/pausing/12480/4 "2003-02-01T17:12:34Z")

</div>

Yeah…

Check this out… What I can tell you probably want is something like a timer… Just call this timer and then when the timer is complete… Start performing the actions again…

if(pauseTimer == 0)  
{  
play();  
} else {  
stop();  
}

Something like that… How you do the timer is your choice then…
