RE: [flexcoders] Is it the right way of using dispatchEvent?

2005-10-20 Thread Abdul Qabiz
] Is it the right way of using dispatchEvent? Hi Abdul,Thanks a lot for giving breif description on "dispatchEvent". One more doubt in this, we declared event before imprting specific classes.Why is it so? I tried doing it in class, but not successfull.What is the reason? And at the

Re: [flexcoders] Is it the right way of using dispatchEvent?

2005-10-19 Thread Ramu p
Hi Abdul,Thanks a lot for giving breif description on dispatchEvent. One more doubt in this, we declared event before imprting specific classes.Why is it so? I tried doing it in class, but not successfull.What is the reason? And at the same time, creating a pure UIComponent in Flasg is a bit

RE: [flexcoders] Is it the right way of using dispatchEvent?

2005-10-18 Thread Abdul Qabiz
Hi, When you extend UIComponent, it comes with event dispatching capabilities. So you don't need to use EventDispatcher.initialize(this) kind of mixin. You need to add [Event("eventName")] metadata in your class/component and just use dispatchEvent(..) method directly. No need to use

RE: [flexcoders] Is it the right way of using dispatchEvent?

2005-10-18 Thread Abdul Qabiz
Look at the following code to figure out what you need to do:- ?xml version="1.0" encoding="utf-8"?mx:Application xmlns:mx="http://www.macromedia.com/2003/mxml" xmlns="*" mx:Script ![CDATA[ function fun(){ mx.controls.Alert.show("Event dispatched!") } ]]/mx:Scriptcircle