I have a parameter that needs to be passed along with an event. After unsuccessful attempts to place it on the type by extending the class, I've been advised in another SO question to write a custom event.
I tried this before but I couldn't figure out how to send it, because I just want to send another parameter with a normal Event.COMPLETE event on a FileReference. I can't have Event.COMPLETE fire and then dispatch my event because then I'll be in the same boat ... the needed parameter won't be in the initial Event.COMPLETE object so I won't be able to dispatch a new event passing that parameter on to the code that actually performs the work.
All help on this is greatly appreciated, need it badly. Thanks.
Basically, I need to replace the Event.COMPLETE functionality exactly as it is, I just need an event that will hold my extra property. Please tell me there's some way to do this.
Could you post some code so we can see how you are approaching this?
However I would highly recommend reading the flex live docs on creating and using custom events.
Here is a simple custom event based application, Take a look at the source, it might be what you are looking for.