# Accessing an Event.COMPLETE listener

**URL:** <https://forum.kirupa.com/t/accessing-an-event-complete-listener/257069>\
**Category:** flash\
**Created:** [April 9, 2008, 10:55pm UTC](https://forum.kirupa.com/t/accessing-an-event-complete-listener/257069 "2008-04-09T22:55:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![skimmmer](https://avatars.discourse-cdn.com/v4/letter/s/9fc348/32.png) [@skimmmer](https://forum.kirupa.com/u/skimmmer)\
**Post date:** [April 9, 2008, 10:55pm UTC](https://forum.kirupa.com/t/accessing-an-event-complete-listener/257069/1 "2008-04-09T22:55:05Z")

</div>

I’m having problems accessing a Event.COMPLETE listener for loading a php file:

```auto
function prepareD(){
           //more code before
          var hsloader:URLLoader = new URLLoader();
          hsloader.dataFormat = URLLoaderDataFormat.VARIABLES;
          hsloader.addEventListener(Event.COMPLETE, highSdata);
          hsloader.load(myData);
           //more code after
            
}
function highSdata(evt:Event){
            if(evt.target.data.highS<(Math.round(musicC/musicL*100))) {
              //code
           } 
}

```

What is happening is I’m creating a new URLloader, then loading the php, and I create a Event.COMPLETE listener, but when the load completes (I’ve tested with navigateToURL), the listener doesn’t trigger. I’ve also tried putting the var before functions, but it doesn’t work either… Any ideas?

Thanks!
