# Pass data to listener?

**URL:** <https://forum.kirupa.com/t/pass-data-to-listener/233883>\
**Category:** Uncategorized\
**Created:** [July 27, 2007, 6:29pm UTC](https://forum.kirupa.com/t/pass-data-to-listener/233883 "2007-07-27T18:29:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![fido\_glc](https://avatars.discourse-cdn.com/v4/letter/f/3da27b/32.png) [@fido\_glc](https://forum.kirupa.com/u/fido_glc)\
**Post date:** [July 27, 2007, 6:29pm UTC](https://forum.kirupa.com/t/pass-data-to-listener/233883/1 "2007-07-27T18:29:36Z")

</div>

I have 2 kinds of images that I want to load into flash. I am using MovieClipLoader class. Is there a way to pass some data to the listener so that when I am loading one kind of the 2, the listener will know and in ‘onLoadComplete’ it will act in a certain way depending on what type of the 2 it is ?  
Something like this:

```auto

loadDataListener.onLoadComplete = function(type:Number):Void {
    if(type == 1) {
        // some behaviours
    } else {
        // other behaviours
    }
}

```
