# Problems creating a debug console

**URL:** https://forum.kirupa.com/t/problems-creating-a-debug-console/299942
**Category:** Uncategorized
**Created:** [November 13, 2009, 4:15am UTC](https://forum.kirupa.com/t/problems-creating-a-debug-console/299942 "2009-11-13T04:15:42Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![zachwlewis](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/zachwlewis/32/350_2.png) [@zachwlewis](https://forum.kirupa.com/u/zachwlewis)
#### Post date: [November 13, 2009, 4:15am UTC](https://forum.kirupa.com/t/problems-creating-a-debug-console/299942/1 "2009-11-13T04:15:42Z")

</div>

I have a platformer with a level editor built in, and I would like to create a console to allow the users to type in simple text commands (“new map 20 40”) to call functions I have set up.

I created a class Console that is an input text box. It sits at the top of the screen and is toggled with the (`/~) key; however, sometimes when I toggle the console, no text appears and I can't activate the text box by clicking on it. It seems that it works when I type something into it before I first deactivate it, but the ideal usage would be, when I press (`/~), the console appears with the cursor in it at the initial location.

Does anyone have any insight into this problem?

_This is an AS3/Flex 3.4 application running in Flash 10. I didn’t use the IDE to create it, and I don’t plan to._

The project is too large for Kirupa forums. Get it at [http://drop.io/consolehelp](http://drop.io/consolehelp)
