# Test for event type does not work

**URL:** <https://forum.kirupa.com/t/test-for-event-type-does-not-work/319967>\
**Category:** flash\
**Created:** [March 10, 2011, 2:10am UTC](https://forum.kirupa.com/t/test-for-event-type-does-not-work/319967 "2011-03-10T02:10:46Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![tonicboy](https://avatars.discourse-cdn.com/v4/letter/t/e19adc/32.png) [@tonicboy](https://forum.kirupa.com/u/tonicboy)\
**Post date:** [March 10, 2011, 2:10am UTC](https://forum.kirupa.com/t/test-for-event-type-does-not-work/319967/1 "2011-03-10T02:10:46Z")

</div>

Hi all,

I have an event handler that handles multiple event types so inside it I am trying to do a test for the event type, which to my understanding is a case-sensitive String. I have a statement such as:

```auto
trace("evt.type: " + evt.type);
if (evt.type=="clicked")
{
	//do something
}

```

The trace statement shows that the evt.type is “clicked” and yet the equality comparison doesn’t work. Tracing ‘evt.type==“clicked”’ shows that it is false. Any clues?
