what you need is a callback function - in the callbackfunction you can then enable the button again
Thanks for your reply!
Would you happen to have direction/an example?
I noticed in some examples that the 'main window' (so below the popup) gets blurred out and has no functionality while the popup is present.
This would fix everything and erase the need to disable the button. How do I do this?
Yes, kinda new at Flex. :-)
actually I cant find a good example to demonstrate it :s
but here is how it should work:
Bare with me as I havent tested it at all..
//as Last parameter add a function, like so:
public function onDialogComplete():void
//enable your button again here
in your popup class
* define a property that is a function
* accept a parameter that is the function
* in the that constructer set the property you made above equal to the new incoming function parameter
then in the function your done - so I guess when you clicked cancel - check if the function != null - then do the callback
- call the function you made
private var _callbackfunction:Function = null;
callbackfunction = onDialogComplete;
//in the function that you want to do the callback
public function close():void
if (callbackfunction != null)
err might look a bit unclear but if it really still is, post the lines of code that refer to your popupmanger
and post the popupmanger and Ill try to fix it for ya
Define a close handler for the popup, and refer to the other component through the main app:
mx.core.Application.application.myOtherComp.myButton.enabled = true;
If this post answers your question or helps, please mark it as such.
Thanks a lot for your enthousiasm, Benji and Greg.
Looking at the code I think it'll be quite transparant and I should make it work, but due to deadlines it'll take a while before I can apply it.
I'll mark the issue as solved, hopefully, it actually will be! :-)
Thanks again, really appreciate the support.