What data type would this be? & tracing the index of an object on stage

okay i know this is lame, but i tried assigning different data types to it but it gives an error. i just wanna strict data type my stuff

i have a addEventListener(MouseEvent.MOUSE_CLICK, myFunc) added to one of my MovieClips on stage. Everytime id want to refernce that object that as been clicked. i would reference it by “event.target” is that correct?

what data type is “event.target”?

lets say i do

var target = event.target;

i traced that using

trace(typeof(target)); // and it returns "object"

however when i try to data type the variable as an object

var target:Object = event.target;

i get an error…

what i am actaully aiming to do is to get the Index of the object. when i tried

getChildIndex(event.target);

i get an error… it only works when i did this


var target = event.target;
trace(getChildIndex(target));

so what datatype is “event.target”?
or is there a better way to get the Index of the Child?

im still a noob at AS3.0 and would like to seek advice.

thank you so much whoever who helps me with this in advance…
and sorry for this stupid question