# Is there anyway to dispatchEvent with a fuction delcared inside the class?

**URL:** https://forum.kirupa.com/t/is-there-anyway-to-dispatchevent-with-a-fuction-delcared-inside-the-class/213467
**Category:** flash
**Created:** [January 19, 2007, 8:28pm UTC](https://forum.kirupa.com/t/is-there-anyway-to-dispatchevent-with-a-fuction-delcared-inside-the-class/213467 "2007-01-19T20:28:41Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![DavidOrtiz](https://avatars.discourse-cdn.com/v4/letter/d/e480ec/32.png) [@DavidOrtiz](https://forum.kirupa.com/u/DavidOrtiz)
#### Post date: [January 19, 2007, 8:28pm UTC](https://forum.kirupa.com/t/is-there-anyway-to-dispatchevent-with-a-fuction-delcared-inside-the-class/213467/1 "2007-01-19T20:28:41Z")

</div>

Hi guys, I’ve got a class where I’m using:

o.type = “focus”;  
o.target = “this”;  
dispatchEvent(o);

and then focus is a function of an object in the FLA.

I want focus to be in the AS External Class file but it won’t trigger.

any ideaS?

thanks.
