In FLEX2 the createPopUp function only has 3 parameters now, referance to the parrent, referance to the window's code, and model state.
--- In [email protected], "Doodi, Hari - BLS CTR" <[EMAIL PROTECTED]> wrote: > > I think the best way to pass values to popup window is to use init > object methodology. > > Declare variables in myPopup.mxml > > For example > > var firstName:String; > > var lastName:String; > > > > In the parent mxml file > > Create an object. Assign values to above said attributes. > > Example > > var initObj:Object = new Object(); > > initObj.firstName = "zzzzzz"; // should match > variable declared in myPopup.mxml > > initObj.lastName = "xxxxxxx"; // should match variable > declared in myPopup.mxml > > > > then pass this initObj > > > > var popupWindow:TitleWindow = TitleWindow(PopUpManager.createPopUp (this, > myPopup, true,initObj)); > > > > > > Thanks! > Hari > > -----Original Message----- > From: [email protected] [mailto:[EMAIL PROTECTED] On > Behalf Of Spike > Sent: Tuesday, October 18, 2005 10:43 AM > To: [email protected] > Subject: Re: [flexcoders] Flex 2: Passing to a PopupWindow > > > > Here's one way to do it: > > ********************************************************** > <?xml version="1.0" encoding="utf-8"?> > <mx:Application xmlns:mx="http://www.macromedia.com/2005/mxml" > xmlns="*"> > > <mx:Script> > <![CDATA[ > import mx.managers.PopUpManager; > import mx.containers.TitleWindow; > import mx.controls.TextInput; > > private function showPopUp(event:Event):Void { > var tw:TitleWindow = new TitleWindow(); > tw.title = "My Title"; > > var input:TextInput = new TextInput(); > input.text = "Hello!"; > tw.addChild(input); > > PopUpManager.popUpWindow(tw, this, false); > } > > > > ]]> > </mx:Script> > > > <mx:Button label="Test popup" click="showPopUp(event);" /> > > </mx:Application> > ********************************************************************** ** > ** > > HTH > > Spike > > > > On 10/18/05, Greg Johnson <[EMAIL PROTECTED]> wrote: > > Ok, I can get the basic popup window fine. Hand to scratch the old > popupwindow code I had gotten from cflex.net because it was throwing > tons of errors in Flex 2. Thing is, I can't figure out how to set a > text field in the popup when it's called. > > > > > > > -- > Flexcoders Mailing List > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt > Search Archives: > http://www.mail-archive.com/flexcoders%40yahoogroups.com > Yahoo! Groups Links > > > > > > > > > > > > > > -- > -------------------------------------------- > Stephen Milligan > Do you do the Badger? > http://www.yellowbadger.com > > Do you cfeclipse? http://www.cfeclipse.org > > > > -- > Flexcoders Mailing List > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt > Search Archives: > http://www.mail-archive.com/flexcoders%40yahoogroups.com > > > > > SPONSORED LINKS > > Web site design development > <http://groups.yahoo.com/gads? t=ms&k=Web+site+design+development&w1=Web+ > site+design+development&w2=Computer+software+development&w3=Software+d es > ign+and+development&w4=Macromedia+flex&w5=Software+development+best+pr ac > tice&c=5&s=166&.sig=L-4QTvxB_quFDtMyhrQaHQ> > > Computer software development > <http://groups.yahoo.com/gads? t=ms&k=Computer+software+development&w1=We > b+site+design+development&w2=Computer+software+development&w3=Software +d > esign+and+development&w4=Macromedia+flex&w5=Software+development+best+ pr > actice&c=5&s=166&.sig=lvQjSRfQDfWudJSe1lLjHw> > > Software design and development > <http://groups.yahoo.com/gads? t=ms&k=Software+design+and+development&w1= > Web+site+design+development&w2=Computer+software+development&w3=Softwa re > +design+and+development&w4=Macromedia+flex&w5=Software+development+bes t+ > practice&c=5&s=166&.sig=1pMBCdo3DsJbuU9AEmO1oQ> > > Macromedia flex > <http://groups.yahoo.com/gads? t=ms&k=Macromedia+flex&w1=Web+site+design+ > development&w2=Computer+software+development&w3=Software+design+and+de ve > lopment&w4=Macromedia+flex&w5=Software+development+best+practice&c=5&s =1 > 66&.sig=OO6nPIrz7_EpZI36cYzBjw> > > Software development best practice > <http://groups.yahoo.com/gads? t=ms&k=Software+development+best+practice& > w1=Web+site+design+development&w2=Computer+software+development&w3=Sof tw > are+design+and+development&w4=Macromedia+flex&w5=Software+development+ be > st+practice&c=5&s=166&.sig=f89quyyulIDsnABLD6IXIw> > > > > > > ________________________________ > > YAHOO! GROUPS LINKS > > > > * Visit your group "flexcoders > <http://groups.yahoo.com/group/flexcoders> " on the web. > > > * To unsubscribe from this group, send an email to: > [EMAIL PROTECTED] > <mailto:[EMAIL PROTECTED]> > > > * Your use of Yahoo! Groups is subject to the Yahoo! Terms of > Service <http://docs.yahoo.com/info/terms/> . > > > > ________________________________ > ------------------------ Yahoo! Groups Sponsor --------------------~--> Get Bzzzy! (real tools to help you find a job). Welcome to the Sweet Life. http://us.click.yahoo.com/A77XvD/vlQLAA/TtwFAA/nhFolB/TM --------------------------------------------------------------------~-> -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/

