Creating a Pop up and setting its view state before it displays

Posted by theringostarrs on Stack Overflow See other posts from Stack Overflow or by theringostarrs
Published on 2009-06-29T09:18:14Z Indexed on 2010/05/06 14:38 UTC
Read the original article Hit count: 152

Filed under:
|
|
|

Hi,

I am a beginner developer in Flex, and I have been using viewstates lately. I had a couple of custom popup titlewindow components that are initialized using:

PopUpManager.createPopUp(this, ContentCreate, true);

They both contain view states already, and are very similar so I wanted to combione them into one popup titlewindow and change view state on initialisation of the popup to either the Create version of the popup or the Update.

I thought I was being smart haha, but I realized soon after refactoring my code that, I as far as I know I can't pass parameters to the popup to indicate which state I want, if it is created using the PopUpManager.

Does anyone know how to pass parameters to the PopupManager, or create the ContentCreate component(TitleWindow) in mxml or code so I can specify the view state?

© Stack Overflow or respective owner

Related posts about flex

Related posts about viewstate