Quantcast
Channel: Adobe Community: Message List
Viewing all articles
Browse latest Browse all 114192

Re: TypeError: Error #1009

$
0
0

I think I solved it. It seems like the program wanted me to set a variable as a Textfield and make it to equal to my instance, GroupNum.

 

I have another error with the trace output though. I have another scene with the exact same code, but slightly different.

 

My Code #2:

 

this.stop();

 

stage.addEventListener(KeyboardEvent.KEY_DOWN, conditionNum);

 

function conditionNum(event:KeyboardEvent):void

{

    var input2:TextField = Condition;

   

    if(event.keyCode < 49 || event.keyCode > 57 && event.keyCode < 97 || event.keyCode > 105)

    {

        trace("Condition: " + input2);

        gotoAndPlay(1, "Scene 3");

    }

}

 

My issue with the trace output is that when this code runs, it's tracing the output from the previous scene as well.

 

Trace Output:

 

Sat Sep 27 01:19:02 GMT-0400 2014

Group #: [object TextField]

Sat Sep 27 01:19:02 GMT-0400 2014

Group #: null

Condition: [object TextField]

Sat Sep 27 01:19:02 GMT-0400 2014

Group #: null

Condition: [object TextField]

Room #: [object TextField]

 

I need some serious help with this because I have a deadline to meet, and this is seriously holding me back.


Viewing all articles
Browse latest Browse all 114192

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>