Custom MenuBar Component
Well I have tried creating a MenuBar class and I can't get itworking. I started with creating the menuBar in pure ActionScript. This works fine when initialized in the Application line. Code is below. start.as - This works -- -- import mx.controls.MenuBar; import mx.controls.Menu public var MyMenuBar:MenuBar = null; public var OptionA:Menu = null; public var OptionB:Menu = null; public function initApp( Void ):Void { var init: Object = null; init = new Object(); init.width = 100%; MyMenuBar = MenuBar( createChild( MenuBar, MyMenuBar, init) ); OptionA = MyMenuBar.addMenu(Option A); OptionB = MyMenuBar.addMenu(Option B); OptionB.addMenuItem({label:Sub B-1}); OptionB.addMenuItem({label:Sub B-2}); } -- - Now I would like to convert this to a class and make a custom component, it doesn't work. my:MyMenuBar width=100% Here is what I tried with trying to creating the class MyMenuBar.as -- -- import mx.controls.MenuBar; import mx.controls.Menu; class MyMenuBar extends MenuBar { function MyMenuBar() { super(); var MyMenuBar:MenuBar = null; var OptionA:Menu = null; var OptionB:Menu = null; OptionA = MyMenuBar.addMenu(Option A); OptionB = MymenuBar.addMenu(Option B); OptionB.addMenuItem({label:Sub B-1}); OptionB.addMenuItem({label:Sub B-2}); } } -- -- -- Now when I execute this custom component. It doesn't break but just creates a blank MenuBar with no options. A blank bar will show up both times when super(); is there and is not there. Any ideas? Any help? Thanks!
Re: Cairngorm - Getting Started PDF manual
Clint, I would still be interested in publishing your article as well. Let me know. Jeff - Original Message - From: Clint Tredway [EMAIL PROTECTED] To: flexcoders@yahoogroups.com Sent: Wednesday, March 16, 2005 11:55 AM Subject: Re: [flexcoders] Cairngorm - Getting Started PDF manual I have one that is about ready to publish.. my old employer didn't want me to let this article out why I was working there... even though I told them it was a how-to or a Cairngorm 101... now that I am not there anymore I will put it on my blog... On Wed, 16 Mar 2005 15:25:25 -0300, Rafael M. Martinelli [EMAIL PROTECTED] wrote: Hi everybody!! Does anybody knows if there's a Cairngorm project releases manual. I found this comment at richinternetapps.com: Next week, a Cairngorm - Getting Started PDF manual will be made available... I couldn't find it!!! Also, congratulations for the Cairngorm project members. Very good framework. Thanks. Rafael -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.7.2 - Release Date: 11/3/2005 Yahoo! Groups Links -- My Blog http://www.clinttredway.com Are you diabetic? http://www.diabetesforums.com Yahoo! Groups Links
RE: [flexcoders] TextInput Focused F2
thank's very much, turning at times a problem the things they become simpler Devis -Original Message- From: Dirk Eismann [EMAIL PROTECTED] To: flexcoders@yahoogroups.com Date: Tue, 15 Mar 2005 14:20:56 +0100 Subject: RE: [flexcoders] TextInput Focused F2 Check for the key code 113 which refers to the F2 key: mx:TextInput keyDown=if (Key.isDown(113)) alert('F2 pressed'); / Dirk. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 15, 2005 2:09 PM To: Flex Coders Subject: [flexcoders] TextInput Focused F2 hi, i wish when user press for example F2 into TextInput show a popWindow, is it possible with flex/actionScript? Can you give me please a bit code Thank's Devis Yahoo! Groups Links
sorry test my email
sorry it's only a test for my email i have had problem to post in flexcoders yesterday.
Re: [flexcoders] List / DataGrid height problem
Hi Matt, thanks for your help. I changed my design, it works now. Greets Christoph Matt Chotin schrieb: No real other ideas off-hand, and no time to experiment, sorry! Matt -Original Message- From: Christoph Guse [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 16, 2005 1:18 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] List / DataGrid height problem Hi Matt, i tried a real value and undefined instead of 100%, didn't help. Perhaps you have another idea, otherwise I have to change my layout. I prefer the first option ;-) Good night Christoph Matt Chotin schrieb: I'm not sure that the percentages are really going to work within a cell renderer. Basically if you have a preferred height the row will size to that row. But if you give it a percentage the row doesn't know how tall you really are meant to be. So maybe try using a real value instead of 100%? Even undefined might actually be the right value so that it tries to size to the preferred size of the children. Matt *From:* Christoph Guse [mailto:[EMAIL PROTECTED] *Sent:* Wednesday, March 16, 2005 9:43 AM *To:* flexcoders@yahoogroups.com *Subject:* Re: [flexcoders] List / DataGrid height problem Hi Matt, you are right. I give you some snippets of my code. List / DataGrid mx:List id=Aufgabenliste width=100% height=100% variableRowHeight=true dataProvider={aufgabenData} cellRenderer=aufgaben.AufgabenCellRenderer/mx:List !-- mx:DataGrid id=Aufgabenliste width=100% height=100% variableRowHeight=true mx:dataProvider {aufgabenData} /mx:dataProvider mx:columns mx:Array mx:DataGridColumn headerText={gridTitle} cellRenderer=aufgaben.AufgabenCellRenderer / /mx:Array /mx:columns /mx:DataGrid Part of my CellRenderer (AufgabenCellRenderer) function doResize(){ var aufgViewHelper = ViewLocator.getInstance().getViewHelper( aufgabenView ); if(close){ aufgabePanel.height=100%; close = false; state = schließen; } else{ aufgabePanel.height=28; close = true; state = öffnen; } aufgViewHelper.refreshList(this); } ]] /mx:Script mx:Panel id=aufgabePanel title={name} status={state} height=28 width=100% mouseDown=doResize() mx:Form mx:FormItem label=Anfang mx:Label text={startDate} / /mx:FormItem mx:FormItem label=fertig bis mx:Label text={endDate}/mx:Label /mx:FormItem mx:FormItem label=Priorität mx:Label text={priority} / /mx:FormItem mx:FormItem label=Status mx:Label text={status} / /mx:FormItem /mx:Form /mx:Panel I should mention, that the List / DataGrid is in a HBox beside another List. If I change the size of one of the lists the row with the CellRenderer is shown correctly once, then the height of the row is static again. Can I broadcast the HBox change event manually? Greets Christoph Matt Chotin schrieb: I assume you have variableRowHeight set to true? -Original Message- From: Christoph Guse [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 16, 2005 1:48 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] List / DataGrid height problem Hi List, I have some trouble with my custom CellRenderer. It is Panel wich expands when you click on it. The initial height is 28pt and when it expands, it has the height it needs. The Problem is, that when you click on it, the Panel expands as expected, but the row height doesn't change. I only get a scrollbar on the right side of the row. I tried several things, like draw() the list, but nothing helped. Any ideas? Thanks a lot Christoph -- Christoph Guse Löhstraße 34 41747 Viersen Tel. 0 21 62 / 50 24 066 Mobil 01 72 / 160 74 84 VoIP 0 12 12 / 39 64 48 831 Yahoo! Groups Links *Yahoo! Groups Sponsor* ADVERTISEMENT click here http://us.ard.yahoo.com/SIG=129sq9p52/M=298184.6018725.7038619.3001176/D=gr oups/S=1705007207:HM/EXP=078124/A=2593423/R=0/SIG=11el9gslf/*http://www. netflix.com/Default?mqso=60190075 http://us.ard.yahoo.com/SIG=129sq9p52/M=298184.6018725.7038619.3001176/D=gr oups/S=1705007207:HM/EXP=078124/A=2593423/R=0/SIG=11el9gslf/*http:/www.n etflix.com/Default?mqso=60190075 *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] mailto:[EMAIL PROTECTED] * Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service http://docs.yahoo.com/info/terms/. -- Christoph Guse Löhstraße 34 41747 Viersen Tel. 0 21 62 / 50 24 066 Mobil 01 72 / 160 74 84 VoIP 0 12 12 / 39 64 48 831 *Yahoo! Groups Sponsor* ADVERTISEMENT click here
Help with array urgently
Sorry, but i don't know ActionScript, i'm using amf. In my mxml file i'm using an array vopf:Array, but if my array is initialized from onResult work in all project. (see my binding please) but if create a new array don't work, for example i wish in my function New_Product() create a function like this function New_Product() { vopf=new Array(); PfVO vo = new PfVO(); vopf.push(vopf); } but from this moment , after call above function, all my binding don't work. Can you help me please Devis class vo.as400.PfVO { public var aacupf : Number; public var blrepf : String; public var cartpf : String; public var cdogpf : String; public var ceaqpf : Number; public var ceulpf : Number; public var cfpfpf : vo.as400.CCategoriFiscaleVO; public var civapf : String; public var cma1pf : String; public var cma2pf : String; public var cma3pf : String; public var cma4pf : String; public var cma5pf : String; public var cmp1pf : String; public var cmp2pf : String; public var cmp3pf : String; public var cnaqpf : String; public var cnvepf : String; public var coaqpf : Number; public var coulpf : Number; public var de50pf : String; public var dtumpf : Number; public var fl10pf : String; public var fl20pf : String; public var fl30pf : String; public var fl31pf : String; public var fl32pf : String; public var fl33pf : String; public var fl34pf : String; public var fl35pf : String; public var fl36pf : String; public var fl37pf : String; public var fl38pf : String; public var fl39pf : String; public var fl40pf : String; public var fl41pf : String; public var fl42pf : String; public var fl43pf : String; public var fl44pf : String; public var fl45pf : String; public var fl46pf : String; public var fl47pf : String; public var fl48pf : String; public var fl49pf : String; public var fla1pf : String; public var fla2pf : String; public var fla3pf : String; public var fla4pf : String; public var fla5pf : String; public var fla6pf : String; public var fla7pf : String; public var fla8pf : String; public var flicpf : String; public var fptgpf : String; public var ftcopf : String; public var ggcupf : Number; public var linepf : String; public var ltripf : Number; public var marcpf : String; public var mmcupf : Number; public var modevo : vo.as400.ModeVO; public var nrazpf : Number; public var orumpf : Number; public var peunpf : Number; public var pfvopk : vo.pk.PfVOPK; public var qmxbpf : Number; public var ricopf : String; public var scmnpf : Number; public var slinpf : String; public var socupf : Number; public var stagione : vo.as400.CStagione; public var strepf : String; public var volupf : Number; public static var registered:Boolean = Object.registerClass( vo.as400.PfVO, vo.as400.PfVO ); }mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundColor=#FF initialize=initApp();initPF(); themeColor=haloSilver xmlns=* !--WorkFlow Scheda Modello -- mx:RemoteObject id=CSchedaModello named=FSchedaModelloRO fault=errorCall(event.fault.description) showBusyCursor=true mx:method name=getAllSeasonsPF result=vopf=onResult(event.result)/ mx:method name=New_Prodcut result=vopf=onResult(event.result)/ /mx:RemoteObject mx:RemoteObject id=CTabelle named=FTabelleRO fault=errorCall(event.fault.description) showBusyCursor=true mx:method name=getAllSeasons result=stagione=onResult(event.result)/ mx:method name=getAllMarchio result=marchio=onResult(event.result)/ mx:method name=getCategorie result=categorie=onResult(event.result)/ mx:method name=getLinee result=linee=onResult(event.result)/ mx:method name=getTaglie result=taglie=onResult(event.result)/ /mx:RemoteObject !--Stagione -- mx:Binding source={PfVO(vopf[0]).stagione.dsc_stag==undefined ?'':PfVO(vopf[0]).stagione.dsc_stag} destination=lstag.text / mx:Binding source={ltrim(PfVO(vopf[0]).stagione.cdc_stag)==undefined ?'':ltrim(PfVO(vopf[0]).stagione.cdc_stag)} destination=PfVO(vopf[0]).pfvopk.stagpf / mx:Binding source={ltrim(PfVO(vopf[0]).stagione.cdc_stag)==undefined ?'':ltrim(PfVO(vopf[0]).stagione.cdc_stag)} destination=PfVO(vopf[0]).modevo.modevopk.stagmo / !--Modello -- mx:Binding source={PfVO(vopf[0]).pfvopk.modepf==undefined ?'':PfVO(vopf[0]).pfvopk.modepf} destination=lmodello.text / mx:Binding source={ltrim(PfVO(vopf[0]).pfvopk.modepf)==undefined ?'':ltrim(PfVO(vopf[0]).pfvopk.modepf)} destination=PfVO(vopf[0]).modevo.modevopk.modemo / !--Tessuto -- mx:Binding source={PfVO(vopf[0]).pfvopk.matepf==undefined ?'':PfVO(vopf[0]).pfvopk.matepf} destination=ltessuto.text / !--Codice Taglia + Taglia Base -- mx:Binding source={PfVO(vopf[0]).modevo.tgbamo==undefined ?'':PfVO(vopf[0]).modevo.tgbamo} destination=tag_base.text / mx:Binding source=tg_base.text==undefined ?'':tg_base.text destination=PfVO(vopf[0]).modevo.ctg1mo / !--Categoria Merceologia prodotto finito -- mx:Binding source={PfVO(vopf[0]).modevo.cmpfmo.dsc_cmpf==undefined ?'':PfVO(vopf[0]).modevo.cmpfmo.dsc_cmpf} destination=lcat_merc.text / mx:Binding
Help Array
Hi can you help to correct this problem function initPF() { vopf=new Array(); pf = new PfVO(); pf.stagione.cdc_stag=2005; vopf.push(pf); } mx:Binding source={PfVO(vopf[0]).stagione.cdc_stag==undefined ?'NK':PfVO(vopf[0]).stagione.cdc_stag} destination=lstag.text / But display always NK??? but if i use mx:Binding source={pf.stagione.cdc_stag==undefined ?'NK':PfVO(pf.stagione.cdc_stag} destination=lstag.text / work fine Can you help me please. Devis
flashgateway.Gateway.getHttpRequest().getSession(true);
Hi, from flex i must set un Object ActionScript into session Servlet, and from java i must retrive this object . if you can help, to me throws always ava.lang.NullPointerException Bye Devis Java side // HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(false); HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(true); PfVO vo =(PfVO)session.getAttribute(vopf); ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundColor=#FF height=80% width=80% mx:RemoteObject id=servlet source=servlet/ mx:Script ![CDATA[ import mx.controls.Alert; import vo.as400.*; var vopf:PfVO; function genPDF() { vopf=new PfVO(); vopf.de50pf=Balsemin; vopf.stagione.cdc_stag=1995; vopf.strepf=A; servlet.session(set,vopf); var pdf_url = /test/view/JavaPdf.pdf; getURL(pdf_url,'_blank'); } ]] /mx:Script mx:Panel title=Printing to a pdf height=100% width=100% mx:Label text=Enter some below and then press the print button. width=100%/ mx:TextInput id=t1 text=Enter some text here! width=80%/ mx:ControlBar mx:Button label=Print click=genPDF()/ /mx:ControlBar /mx:Panel /mx:Applicatio
EditField
Please can you help me, i have this function function updateObj(oEvent:Object,sColumn:String):Void { vopf.editField(0, sColumn, oEvent.target.text); } and this pojo ActionScript class vo.as400.PfVO { public var aacupf : Number; public var blrepf : String; public var cartpf : String; public var cdogpf : String; public var ceaqpf : Number; public var ceulpf : Number; public var cfpfpf : vo.as400.CCategoriFiscaleVO; } if use updateObj('cartpf','CIAO') work updateObj('cfpfpf.modepf','PIZZA') don't work Can you help me please Devis
EditField
Please can you help me, i have this function function updateObj(oEvent:Object,sColumn:String):Void { vopf.editField(0, sColumn, oEvent.target.text); } and this pojo ActionScript class vo.as400.PfVO { public var aacupf : Number; public var blrepf : String; public var cartpf : String; public var cdogpf : String; public var ceaqpf : Number; public var ceulpf : Number; public var cfpfpf : vo.as400.CCategoriFiscaleVO; } if use updateObj('cartpf','CIAO') work updateObj('cfpfpf.modepf','PIZZA') don't work Can you help me please Devis
flashgateway.Gateway.getHttpRequest().getSession(true);
Hi, from flex i must set un Object ActionScript into session Servlet, and from java i must retrive this object . if you can help, to me throws always ava.lang.NullPointerException Bye Devis Java side // HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(false); HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(true); PfVO vo =(PfVO)session.getAttribute(vopf); ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundColor=#FF height=80% width=80% mx:RemoteObject id=servlet source=servlet/ mx:Script ![CDATA[ import mx.controls.Alert; import vo.as400.*; var vopf:PfVO; function genPDF() { vopf=new PfVO(); vopf.de50pf=Balsemin; vopf.stagione.cdc_stag=1995; vopf.strepf=A; servlet.session(set,vopf); var pdf_url = /test/view/JavaPdf.pdf; getURL(pdf_url,'_blank'); } ]] /mx:Script mx:Panel title=Printing to a pdf height=100% width=100% mx:Label text=Enter some below and then press the print button. width=100%/ mx:TextInput id=t1 text=Enter some text here! width=80%/ mx:ControlBar mx:Button label=Print click=genPDF()/ /mx:ControlBar /mx:Panel /mx:Applicatio
EditField
Please can you help me, i have this function function updateObj(oEvent:Object,sColumn:String):Void { vopf.editField(0, sColumn, oEvent.target.text); } and this pojo ActionScript class vo.as400.PfVO { public var aacupf : Number; public var blrepf : String; public var cartpf : String; public var cdogpf : String; public var ceaqpf : Number; public var ceulpf : Number; public var cfpfpf : vo.as400.CCategoriFiscaleVO; } if use updateObj('cartpf','CIAO') work updateObj('cfpfpf.modepf','PIZZA') don't work Can you help me please Devis
sorry for all flexcoder, my mdeamon has crashed
excuse me but the whole mail that it was firm in these days it has now departed, pardon to all Devis
flashgateway.Gateway.getHttpRequest().getSession(true);
Hi, from flex i must set un Object ActionScript into session Servlet, and from java i must retrive this object . if you can help, to me throws always ava.lang.NullPointerException Bye Devis Java side // HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(false); HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(true); PfVO vo =(PfVO)session.getAttribute(vopf); ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundColor=#FF height=80% width=80% mx:RemoteObject id=servlet source=servlet/ mx:Script ![CDATA[ import mx.controls.Alert; import vo.as400.*; var vopf:PfVO; function genPDF() { vopf=new PfVO(); vopf.de50pf=Balsemin; vopf.stagione.cdc_stag=1995; vopf.strepf=A; servlet.session(set,vopf); var pdf_url = /test/view/JavaPdf.pdf; getURL(pdf_url,'_blank'); } ]] /mx:Script mx:Panel title=Printing to a pdf height=100% width=100% mx:Label text=Enter some below and then press the print button. width=100%/ mx:TextInput id=t1 text=Enter some text here! width=80%/ mx:ControlBar mx:Button label=Print click=genPDF()/ /mx:ControlBar /mx:Panel /mx:Applicatio
Test my email
sorry it's only a test for my email i have had problem to post in flexcoders yesterday.
Datagrid Cell color
Hi I would like to set the color of one cell/column (only a cell, not row) on a row to either red/greed/gray depending on the value of the column value. Anyone has done this before? Wilfred
Re: displaying DataGrid rows based on dataProvider object variable
Thanks so much Manish, Your suggestion is actually how I solved the problem, I just created a function which recreates the dataprovider whenever needed. Thanks again for the response... --- In flexcoders@yahoogroups.com, Manish Jethani [EMAIL PROTECTED] wrote: On Wed, 16 Mar 2005 19:22:44 -, big75blue [EMAIL PROTECTED] wrote: Sorry, I'm a Flex newby, but I have a question regarding the display of rows in a DataGrid. I want to display the current row/object in the DataGrid based on an attribute contained w/in the current row object. For example, I have an Action Script object (representing the current DataGrid row) that contains a Boolean, and I only want to display that row based on that Boolean value. Is this possible? It's surely possible. The easy thing to do is to create a new dataprovider and add only the items you need to it. If you're doing this very often and for different apps, maybe you want to look at this: http://manish.revise.org/archives/2005/01/31/data-filtering-using- a-custom-dataprovider/ Manish
RE: [flexcoders] Cairngorm for a newbie :)
Hi Scott, I think that your understanding of the framework is pretty much correct. The way I look at ViewHelpers is that if you need to make any changes to the bit that the visual part of the App - the View then the code for this should goonly in that Views ViewHelper. For example the user ticks a tick box and the change event for the tick box calls a method in the ViewHelper of a StatusView Component. The method changes some Text of the StatusView to reflect the new status. So the codeis always in a logical placerather than bitsof view control code being distributed all over. Before adopting the Cairngorm Framework I found it hard going. The most difficult part of Flex without the Cairngorm (or similar) framework is locatingObjects/Componentsfrom another Object/Component and standardizing this method. In fact I've taken the whole ethos of these Framework "Patterns" on board, and added a few extras.After looking at the ViewLocator pattern I added a ValueObjectLocator that allowed me to easily access the Apps Data Models from whatever Component or ViewHelper I happen to be in. The cairngorm framework has vastly expanded my understanding of Object Oriented programming and at the same time made my Flex Apps much more understandableand maintainable. I greatly thank Steven Webster and the Cairngorm team for their efforts. Regards, Simon Fifield -Original Message-From: Scott Barnes [mailto:[EMAIL PROTECTED]Sent: 17 March 2005 02:36To: flexcoders@yahoogroups.comSubject: [flexcoders] Cairngorm for a newbie :)I'm currently getting ready to begin a long journey in FLEXdevelopment for a bunch of systems here at work.I've been reading up as much as i can on cairngorm and trying tofigure out its value in FLEX and whether I should adopt it or ploughon without it.So far I've watched Robin Hilliards Breeze preso, sampled some examplecairngorm applications from both I2 guys and Robin.I've outlined some summary notes below, and would absolutely love itif someone here could correct them or expand on them to enableme tounderstand the cairngorm luv :)Heres what I've gathered so far:- formalised approach to command subscriptions, in that a controlleris established which registers itself against commands for both Viewsand Models - but in a relatively simplified syntax (ie addCommand)- Seperating ViewPods from logic via "ViewHelpers". It appears thatthe framework allows a developer to add "behaviours" or "logic" to aview but in a way that its not coupled with that said view (ie iassume you could add a ViewHelper to other ViewPods? - yet all feedoff the one instance/codebase).- Templated Command Objects : it seems to me that the whole Commandconcept has established a base template to work from, so thatonResult, onFault and execute are automatically invoked per command? -then the developer can just fill in the blanks based on the eventtype?- ViewLocator - kind of reminds me of DHTML'sdocument.getElementById() in that it appears each ViewHelper registersitself within cairngorm and the ViewLocator simply provides a dynamicbridge between the actual view and the object requesting its location?or something like that?Thats my note so far, and again I do apologise if its inaccurate inanyway but i'm trying to wrap my headspace into how it implements MVCand why its used.If this is Offtopic I do apologise but *poke* *prod* a "GettingStarted Guide" would of been great ;) heheheheh-- Regards,Scott Barneshttp://www.mossyblog.com
attach/createObject
Hi All, i'am new to this list and new to Flex. i'am a Flash developer and i get a bit confused by the way Flex works. I would like to achieve the following. in Flash using the attachMovie you directly fill a movieclip container with a linked symbol from the library. in Flex i have a class building a container. i would like to be able to do the following in the class container -- attachMovie located in an external swf i saw the embed tag, where you can add an external image or swf into a container. in mxml this one works mx:Image source=@Embed('skins/OPSkin.swf#updownMC') id=updown / this displays the symbol on stage. this in a script tag doesn't work... acoording to documentation it should mx:Script ![CDATA[ function attach() } [Embed('skins/OPSkin.swf#updownMC')] var updownMC:String; // traces undefined } ]] /mx:Script i'am sure i'am missing something somewhere and how do i use this synthax from a class? using createObject()? Any help would be more than welcome. Fabrice
Re: [flexcoders] Re: displaying DataGrid rows based on dataProvider object variable
Any chance you could share the code for that function? I've been struggling with the same problem. Thanks. - Tom At 08:13 AM 3/17/2005, you wrote: Thanks so much Manish, Your suggestion is actually how I solved the problem, I just created a function which recreates the dataprovider whenever needed. Thanks again for the response...
RE: [flexcoders] attach/createObject
Hi Fabrice, Embed metadata works on compile time, right way of doing is: [Embed(source=skins/OPSkin.swf, symbol=updownMC)] var upDownMC:String updownMC symbol would be embedded in your flex app and linkageID would be assigned to updownMC variable declared below the metadata tag Does that help you? -abdul -Original Message- From: Fabrice closier [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 7:24 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] attach/createObject Hi All, i'am new to this list and new to Flex. i'am a Flash developer and i get a bit confused by the way Flex works. I would like to achieve the following. in Flash using the attachMovie you directly fill a movieclip container with a linked symbol from the library. in Flex i have a class building a container. i would like to be able to do the following in the class container -- attachMovie located in an external swf i saw the embed tag, where you can add an external image or swf into a container. in mxml this one works mx:Image source=@Embed('skins/OPSkin.swf#updownMC') id=updown / this displays the symbol on stage. this in a script tag doesn't work... acoording to documentation it should mx:Script ![CDATA[ function attach() } [Embed('skins/OPSkin.swf#updownMC')] var updownMC:String; // traces undefined } ]] /mx:Script i'am sure i'am missing something somewhere and how do i use this synthax from a class? using createObject()? Any help would be more than welcome. Fabrice Yahoo! Groups Links
Re: [flexcoders] attach/createObject
do you mean that now, i can use the id upDownMC the same way i could attach a symbol? fabrice On 17-mrt-05, at 15:17, Abdul Qabiz wrote: Hi Fabrice, Embed metadata works on compile time, right way of doing is: [Embed(source=skins/OPSkin.swf, symbol=updownMC)] var upDownMC:String updownMC symbol would be embedded in your flex app and linkageID would be assigned to updownMC variable declared below the metadata tag Does that help you? -abdul -Original Message- From: Fabrice closier [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 7:24 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] attach/createObject Hi All, i'am new to this list and new to Flex. i'am a Flash developer and i get a bit confused by the way Flex works. I would like to achieve the following. in Flash using the attachMovie you directly fill a movieclip container with a linked symbol from the library. in Flex i have a class building a container. i would like to be able to do the following in the class container -- attachMovie located in an external swf i saw the embed tag, where you can add an external image or swf into a container. in mxml this one works mx:Image source=@Embed('skins/OPSkin.swf#updownMC') id=updown / this displays the symbol on stage. this in a script tag doesn't work... acoording to documentation it should mx:Script ![CDATA[ function attach() } [Embed('skins/OPSkin.swf#updownMC')] var updownMC:String; // traces undefined } ]] /mx:Script i'am sure i'am missing something somewhere and how do i use this synthax from a class? using createObject()? Any help would be more than welcome. Fabrice Yahoo! Groups Links Yahoo! Groups Links
RE: [flexcoders] attach/createObject
do you mean that now, i can use the id upDownMC the same way i could attach a symbol? No, your symbol has only been embedded in your flex app not attached to any container. You still need to use recommended ways(using methods of View or UIObject class) to add children to a container. For example: ##Embed_AS_Test.mxml## mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; mx:Script ![CDATA[ [Embed(source=skins/OPSkin.swf, symbol=upDownMC)] var upDownMC:String function onAppInit() { //add the child to Hbox, not first argument is linkageID or symbolName (in flex world) _hbox.createChild(upDownMC, upDownMC); } ]] /mx:Script mx:Hbox id=_hbox / /mx:Application Please note, attachMovie(..) is not recommended in Flex app. Use the methods of View or UIObject to add/attach children to containers... Hope that helps, -abdul -Original Message- From: Fabrice closier [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 7:58 PM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] attach/createObject do you mean that now, i can use the id upDownMC the same way i could attach a symbol? fabrice On 17-mrt-05, at 15:17, Abdul Qabiz wrote: Hi Fabrice, Embed metadata works on compile time, right way of doing is: [Embed(source=skins/OPSkin.swf, symbol=updownMC)] var upDownMC:String updownMC symbol would be embedded in your flex app and linkageID would be assigned to updownMC variable declared below the metadata tag Does that help you? -abdul -Original Message- From: Fabrice closier [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 7:24 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] attach/createObject Hi All, i'am new to this list and new to Flex. i'am a Flash developer and i get a bit confused by the way Flex works. I would like to achieve the following. in Flash using the attachMovie you directly fill a movieclip container with a linked symbol from the library. in Flex i have a class building a container. i would like to be able to do the following in the class container -- attachMovie located in an external swf i saw the embed tag, where you can add an external image or swf into a container. in mxml this one works mx:Image source=@Embed('skins/OPSkin.swf#updownMC') id=updown / this displays the symbol on stage. this in a script tag doesn't work... acoording to documentation it should mx:Script ![CDATA[ function attach() } [Embed('skins/OPSkin.swf#updownMC')] var updownMC:String; // traces undefined } ]] /mx:Script i'am sure i'am missing something somewhere and how do i use this synthax from a class? using createObject()? Any help would be more than welcome. Fabrice Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links
RE: [flexcoders] EditField
Hi, Did you try passing object reference instead of path? updateObj(cfpfpf.modepf, 'PIZZA'); Does this work? -abdul -Original Message- From: devis [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 16, 2005 6:12 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] EditField Please can you help me, i have this function function updateObj(oEvent:Object,sColumn:String):Void { vopf.editField(0, sColumn, oEvent.target.text); } and this pojo ActionScript class vo.as400.PfVO { public var aacupf : Number; public var blrepf : String; public var cartpf : String; public var cdogpf : String; public var ceaqpf : Number; public var ceulpf : Number; public var cfpfpf : vo.as400.CCategoriFiscaleVO; } if use updateObj('cartpf','CIAO') work updateObj('cfpfpf.modepf','PIZZA') don't work Can you help me please Devis Yahoo! Groups Links
RE: [flexcoders] editable datagrid
Hi, Do you mean, when focus goes to a cell in an editable DataGrid, you want to do some validation/formatting based of the content there? You can probably look at cellFocusIn cellFocusOut events of DataGrid, these are broadcast when a cell gets focus loses focus respectively. You can write your logic in their handlers... Details: cellFocusIn/cellFocusOut's event object contains following properties - itemIndex Index of the selected item. - columnIndex Index of the selected column. - target Reference to the component that triggered the event. - type Name of the event. I have made a simple sample, might be useful for you...Following example shows how you can retrieve data from a focussed cell and how can you modifiy cell data when focus is lost... ##DataGridCellFocusTest.mxml### ?xml version=1.0? mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundColor=#FF mx:Script ![CDATA[ function handleCellFocus(event) { var target = event.target; var index = event.itemIndex; var colIndex = event.columnIndex; var col = target.getColumnAt(colIndex); var item = target.getItemAt(index); var colName = col.columnName; debug_ta.text += Text in Current Cell: + (item[col.columnName]) + \n; } function handleCellFocuOut(event) { var target = event.target; var target = event.target; var index = event.itemIndex; var colIndex = event.columnIndex; var col = target.getColumnAt(colIndex); var item = target.getItemAt(index); var colName = col.columnName; target.editField(index, col.columnName, Math.random()*1000); debug_ta.text += Previous Cell data changed to random num: + (item[col.columnName]) + \n; } ]] /mx:Script mx:Panel title=DataGrid Panel marginTop=10 mx:VBox mx:DataGrid id=myGrid width=350 height=100 cellFocusIn=handleCellFocus(event) cellFocusOut=handleCellFocuOut(event) editable=true mx:dataProvider mx:Array id=arr mx:Object Artist= Kapil Album=All Time Favourites Price=10/ mx:Object Artist= Kapil Album=Classic Songs Price=10/ /mx:Array /mx:dataProvider /mx:DataGrid /mx:VBox mx:TextArea id=debug_ta text= width=300% height=200/ /mx:Panel /mx:Application -abdul -Original Message- From: valysivec27 [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 7:07 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] editable datagrid Hi All, How do I change/replace the content of a cell in an editable data grid when the cell gets focus (depending on the current content). Is there an easy way to do that ? Thanks, Val. Yahoo! Groups Links
Re: [flexcoders] EditField
good Abdul, work fine, can you help with my array post please, i'm stop with my work please. Abdul Qabiz ha scritto: Hi, Did you try passing object reference instead of path? updateObj(cfpfpf.modepf, 'PIZZA'); Does this work? -abdul -Original Message- From: devis [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 16, 2005 6:12 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] EditField Please can you help me, i have this function function updateObj(oEvent:Object,sColumn:String):Void { vopf.editField(0, sColumn, oEvent.target.text); } and this pojo ActionScript class vo.as400.PfVO { public var aacupf : Number; public var blrepf : String; public var cartpf : String; public var cdogpf : String; public var ceaqpf : Number; public var ceulpf : Number; public var cfpfpf : vo.as400.CCategoriFiscaleVO; } if use updateObj('cartpf','CIAO') work updateObj('cfpfpf.modepf','PIZZA') don't work Can you help me please Devis Yahoo! Groups Links Yahoo! Groups Links
RE: [flexcoders] Info
Go back to: /WEB-INF/flex/gateway-config.xml and set the AMF Gateway logger level back to Error. logger level=Errorflex.services.logging.FlexGatewayLogger/logger Then restart Flex app. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 15, 2005 1:24 PM To: Flex Coders Subject: [flexcoders] Info Hi Peter, again Devis, my project in this moment work and my result it's ok. but generate always this logs, but i don't understand. but I have not understood if I have to worry me. Can you help me Devis Yahoo! Groups Links
RE: [flexcoders] flashgateway.Gateway.getHttpRequest().getSession(true);
Hi Devis, I thought I answered this question for you on Monday? -Original Message- From: Peter Farland Sent: Monday, March 14, 2005 10:15 AM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Servlet Session I'd suggest you don't use the session servlet in Flex 1.5. Instead, I'd just write a normal plain old java object façade that calls the thread-localstatic helpers on flashgateway.Gateway public static HttpServletRequest getHttpRequest() public static HttpServletResponse getHttpResponse() public static ServletConfig getServletConfig() You can get access to the current session from the HttpRequest. HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(true); See: http://www.macromedia.com/support/documentation/en/flex/1_5/migration.html#sessions Anyway, here's some more detailed instructions: 1. Write some RemoteObject service as a Java class: - package sample.session; import flex.messaging.HttpContext; import javax.servlet.http.HttpSession; /** * A sample Remoting Service that gets and sets * attributes from the current session... */ public class Session { public Session() { } public Object getSessionObject(String name) { HttpSession session = HttpContext.getHttpRequest().getSession(true); return session.getAttribute(name); } public void setSessionObject(String name, Object o) { HttpSession session = HttpContext.getHttpRequest().getSession(true); session.setAttribute(name, o); } } - 2. Then add this to your remote-objects whitelist in flex-config.xml: object name=mySessionService !-- use-custom-authenticationfalse/use-custom-authentication -- sourcesample.session.Session/source typestateless-class/type allow-unnamed-accessfalse/allow-unnamed-access /object 3. Then change your mx:RemoteObject tag to use this named service: mx:RemoteObject id=sessionService named=mySessionService/ (Also add fault and result handlers!!) 4. Update your script to use this new RemoteObject by id sessionService.
Re: [flexcoders] flashgateway.Gateway.getHttpRequest().getSession(true);
thank's peter, sorry but i have had problem with mail mail server :-( Devis Peter Farland ha scritto: Hi Devis, I thought I answered this question for you on Monday? -Original Message- From: Peter Farland Sent: Monday, March 14, 2005 10:15 AM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Servlet Session I'd suggest you don't use the session servlet in Flex 1.5. Instead, I'd just write a normal plain old java object façade that calls the thread-local static helpers on flashgateway.Gateway public static HttpServletRequest getHttpRequest() public static HttpServletResponse getHttpResponse() public static ServletConfig getServletConfig() You can get access to the current session from the HttpRequest. HttpSession session = flashgateway.Gateway.getHttpRequest().getSession(true); See: http://www.macromedia.com/support/documentation/en/flex/1_5/migration.html#sessions Anyway, here's some more detailed instructions: 1. Write some RemoteObject service as a Java class: - package sample.session; import flex.messaging.HttpContext; import javax.servlet.http.HttpSession; /** * A sample Remoting Service that gets and sets * attributes from the current session... */ public class Session { public Session() { } public Object getSessionObject(String name) { HttpSession session = HttpContext.getHttpRequest().getSession(true); return session.getAttribute(name); } public void setSessionObject(String name, Object o) { HttpSession session = HttpContext.getHttpRequest().getSession(true); session.setAttribute(name, o); } } - 2. Then add this to your remote-objects whitelist in flex-config.xml: object name=mySessionService !-- use-custom-authenticationfalse/use-custom-authentication -- sourcesample.session.Session/source typestateless-class/type allow-unnamed-accessfalse/allow-unnamed-access /object 3. Then change your mx:RemoteObject tag to use this named service: mx:RemoteObject id=sessionService named=mySessionService/ (Also add fault and result handlers!!) 4. Update your script to use this new RemoteObject by id sessionService. Yahoo! Groups Links
RE: [flexcoders] Help Array
Try this: var val:PfVO; function initPF() { vopf=new Array(); pf = new PfVO(); pf.stagione.cdc_stag=2005; vopf.push(pf); val = vopf[0]; } mx:Binding source={PfVO(val ).stagione.cdc_stag==undefined ?'NK':PfVO(val).stagione.cdc_stag} destination=lstag.text / I don't know much about Binding, but can we watch a[0] kind of thing? Don't know :( I have created a sample file to test this approach, it works..You can find a way by doing something like that... ###BindingTest.mxml### ?xml version=1.0 encoding=iso-8859-1? mx:Application width=800 height=600 xmlns:mx=http://www.macromedia.com/2003/mxml; xmlns=* initialize=appInit() mx:Script ![CDATA[ var arr:Array; var val:TestVO; function appInit() { arr = []; var tvo = new TestVO(); tvo.name = Abdul; arr.push(tvo); val = arr[0]; } ]] /mx:Script mx:Binding source={TestVO(val).name== undefined ? 'No Name':TestVO(val).name} destination=_ti.text / mx:TextInput id=_ti/ /mx:Application ##TestVO.as## class TestVO { public var name:String; } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 15, 2005 10:17 PM To: Flex Coders Subject: [flexcoders] Help Array Hi can you help to correct this problem function initPF() { vopf=new Array(); pf = new PfVO(); pf.stagione.cdc_stag=2005; vopf.push(pf); } mx:Binding source={PfVO(vopf[0]).stagione.cdc_stag==undefined ?'NK':PfVO(vopf[0]).stagione.cdc_stag} destination=lstag.text / But display always NK??? but if i use mx:Binding source={pf.stagione.cdc_stag==undefined ?'NK':PfVO(pf.stagione.cdc_stag} destination=lstag.text / work fine Can you help me please. Devis Yahoo! Groups Links
RE: [flexcoders] Datagrid Cell color
Hi, I guess, you can easily do it by writing simple Custom CellRenderer and keeping your loging inside setValue(..) function There might be some direct ways by using DataGrid or DataGridColumn APIs, but I am not too sure about it... -abdul -Original Message- From: Wilfred LEUNG [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 6:00 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Datagrid Cell color Hi I would like to set the color of one cell/column (only a cell, not row) on a row to either red/greed/gray depending on the value of the column value. Anyone has done this before? Wilfred Yahoo! Groups Links
RE: [flexcoders] Help with array urgently
Array.Push does not emit the dataProvider change event. Instead use the DataProvider API method: Vopf.addItem(PfVO) Tracy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 5:42 AM To: Flex Coders Subject: [flexcoders] Help with array urgently Sorry, but i don't know ActionScript, i'm using amf. In my mxml file i'm using an array vopf:Array, but if my array is initialized from onResult work in all project. (see my binding please) but if create a new array don't work, for example i wish in my function New_Product() create a function like this function New_Product() { vopf=new Array(); PfVO vo = new PfVO(); vopf.push(vopf); } but from this moment , after call above function, all my binding don't work. Can you help me please Devis Yahoo! Groups Links
Re: [flexcoders] Help with array urgently
Thank's work, but there is best approch for to do this function Create_Product() { myViewStack.selectedIndex=0; arr = []; var pfvo = new PfVO(); var pfpk = new PfVOPK(); var modevo = new ModeVO(); var modepk = new ModeVOPK(); var stag = new CStagione(); var ccmpf = new CCmpf(); pfvo.pfvopk=pfpk; pfvo.modevo=modevo; pfvo.modevo.modevopk=modepk; pfvo.modevo.ccmpf=ccmpf; pfvo.strepf=''; arr.push(pfvo); vopf.addItem(pfvo) } or it's correct to init all suboject of PfVO class Devis Tracy Spratt ha scritto: Array.Push does not emit the dataProvider change event. Instead use the DataProvider API method: Vopf.addItem(PfVO) Tracy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 5:42 AM To: Flex Coders Subject: [flexcoders] Help with array urgently Sorry, but i don't know ActionScript, i'm using amf. In my mxml file i'm using an array vopf:Array, but if my array is initialized from onResult work in all project. (see my binding please) but if create a new array don't work, for example i wish in my function New_Product() create a function like this function New_Product() { vopf=new Array(); PfVO vo = new PfVO(); vopf.push(vopf); } but from this moment , after call above function, all my binding don't work. Can you help me please Devis Yahoo! Groups Links Yahoo! Groups Links
RE: [flexcoders] TabNavigator.
Well, I expected selectedIndex = undefined; or selectedIndex = -1; to work but they didn't. I did discover that if you re-assign the dataProvider for the NavBar, all the tabs become un-selected. Tracy -Original Message- From: Gareth Edwards [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 1:07 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] TabNavigator. I have begun trying to get this to work. There is a fairly major issue I have come accross.. in that if I create multipul rows say I have 3.. then I have 3 tabs selected as default.. one for each row, does anyone know of a way of deselecting a tab from a tabBar? Gareth. On Tue, 8 Mar 2005 11:50:26 -0500, Tracy Spratt [EMAIL PROTECTED] wrote: Not inherently. Most Containers have a default vertical spacing that you would need to override with verticalGap=0. A TabBar in a repeater sounds like a great custom component. If you build one, please share it! Tracy -Original Message- From: Gareth Edwards [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 08, 2005 5:50 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] TabNavigator. Wouldnt that put a space between each tab row? On Mon, 7 Mar 2005 09:34:32 -0800, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: try using the tabBar and the repeater tag. -Art Quoting Gareth Edwards [EMAIL PROTECTED]: Unfortunately around 30 tabs is as specific as we can get at the moment. Its quite a large project with some standards that have already been put in place for multirow tabs. The DHTML versions of the controls required are finished and it would be a shame to have to write custom components to get similar functionality out of flex. Gareth. Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links
RE: [flexcoders] Making the list archives searchable
Manish, I'll look into this as a matter of course ... thanks for bringing this to our attention. Best, Steven -Original Message- From: Manish Jethani [mailto:[EMAIL PROTECTED] Sent: 17 March 2005 18:00 To: Flexcoders Subject: [flexcoders] Making the list archives searchable Today I was at MAX India in Bangalore, and one of the things I noticed was, not only did people have a hard time finding technical information about Flex, some of them also had no clue about Flexcoders. Anyway, let's fix some of it. I want to make the list archives searchable in the true sense (like Google, like Yahoo, like MSN, ... not like Yahoo Groups). There's a couple of things we need to do: 1. Subscribe [EMAIL PROTECTED] to the list. I've already asked for a subscription, but the process can be faster if the admin of this list directly subscribes that email address. More information on http://www.mail-archive.com/ 2. The previous one only takes care of new mail. We also want the old mail (ever since the first message) to be searchable. The first step in doing that is to get the archives. I'm not sure if Yahoo provides these, but I know how to get them otherwise. What I need: if someone can afford it, please volunteer some web hosting space for hosting the archives. If you can run Perl directly on the same server, that's even better. I'm expecting we'll have at least 100 MB of text to host (split into say 100 files). There were 11,418 messages the last time I checked. 3. Once we have the archives hosted somewhere, we'll simply link to them from our blogs/websites and the search engines will pick them up. Joy! So email me off list if you have web space and can afford to host. Manish Yahoo! Groups Links -- No virus found in this incoming message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.7.3 - Release Date: 15/03/2005 -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.7.3 - Release Date: 15/03/2005
Re: [flexcoders] Help Array
Hi can you help to correct this problem I don't know much about Binding, but can we watch a[0] kind of thing? Don't know :( The problem is that you're trying to use a databinding expression on an array element (vopf[0]). Flex can only bind to variables or get functions with defined changed events. The binding expression is triggered when you set vopf to a new Array (since vopf is a variable in the binding expression), which sets Istag.text to 'NK'. The expression is not triggered when you push pf into vopf, so Istag.text is never updated with the correct value. The solution provided by Abdul will will work fine if you can set a array element to a variable. If this is the case, however, you probably don't need an array. Another solution is to trigger the databinding manually. You can do this by calling executeBindings()' on your view elements (which may also be impractical), or you can do something like this: function initPF() { var a =new Array(); pf = new PfVO(); pf.stagione.cdc_stag=2005; a.push(pf); vopf = a; } The 'vopf = a' at the end will trigger the bindings after the array has been set, so you should get the updated value. Alex Carbon Five On Thu, 17 Mar 2005 08:23:31 -0800, Abdul Qabiz [EMAIL PROTECTED] wrote: Try this: var val:PfVO; function initPF() { vopf=new Array(); pf = new PfVO(); pf.stagione.cdc_stag=2005; vopf.push(pf); val = vopf[0]; } mx:Binding source={PfVO(val ).stagione.cdc_stag==undefined ?'NK':PfVO(val).stagione.cdc_stag} destination=lstag.text / I don't know much about Binding, but can we watch a[0] kind of thing? Don't know :( I have created a sample file to test this approach, it works..You can find a way by doing something like that... ###BindingTest.mxml### ?xml version=1.0 encoding=iso-8859-1? mx:Application width=800 height=600 xmlns:mx=http://www.macromedia.com/2003/mxml; xmlns=* initialize=appInit() mx:Script ![CDATA[ var arr:Array; var val:TestVO; function appInit() { arr = []; var tvo = new TestVO(); tvo.name = Abdul; arr.push(tvo); val = arr[0]; } ]] /mx:Script mx:Binding source={TestVO(val).name== undefined ? 'No Name':TestVO(val).name} destination=_ti.text / mx:TextInput id=_ti/ /mx:Application ##TestVO.as## class TestVO { public var name:String; } -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 15, 2005 10:17 PM To: Flex Coders Subject: [flexcoders] Help Array Hi can you help to correct this problem function initPF() { vopf=new Array(); pf = new PfVO(); pf.stagione.cdc_stag=2005; vopf.push(pf); } mx:Binding source={PfVO(vopf[0]).stagione.cdc_stag==undefined ?'NK':PfVO(vopf[0]).stagione.cdc_stag} destination=lstag.text / But display always NK??? but if i use mx:Binding source={pf.stagione.cdc_stag==undefined ?'NK':PfVO(pf.stagione.cdc_stag} destination=lstag.text / work fine Can you help me please. Devis Yahoo! Groups Links Yahoo! Groups Sponsor ADVERTISEMENT 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 the Yahoo! Terms of Service.
Re: [flexcoders] Question about changing the color of something
On Thu, 17 Mar 2005 09:52:27 -0500, Matt Horn [EMAIL PROTECTED] wrote: I believe the reason is performance. I agree. It's actually code size, to be specific. If color were a property, it would be implement like this: function set color(value:Object):Void { setStyle(color, value); } You can still do this if you extend a class from the framework. The problem with this is, all the styles would become properties of the objects and that would increase the size of the code. Manish
Re: [flexcoders] Custom MenuBar Component
On Thu, 17 Mar 2005 01:15:59 -, wesflex73 [EMAIL PROTECTED] wrote: OptionA = MyMenuBar.addMenu(Option A); OptionB = MymenuBar.addMenu(Option B); You want that to be: OptionA = addMenu(Option A); OptionB = addMenu(Option B); Manish
CMP Media's Software Development Magazine Announces Winners for the 15th Annual Jolt Product Excellence Productivity Awards
http://www.prnewswire.com/cgi-bin/stories.pl?ACCT=109STORY=/www/story/03-17-2005/0003204586EDATE= SAN FRANCISCO, March 17 /PRNewswire-FirstCall/ -- Winners of the 15th Annual Software Development Jolt Product Excellence and Productivity Awards were announced last night, Wednesday, March 16, by the editors of Software Development magazine. The Jolt awards ceremony was held at the SD West Conference Exposition at the Santa Clara Convention Center in California's Silicon Valley. Web Development Tools Jolt Winner: -- Macromedia Flex 1.5 (Macromedia)
Re: [flexcoders] Making the list archives searchable
Manish Jethani wrote: I want to make the list archives searchable in the true sense (like Google, like Yahoo, like MSN, ...not like Yahoo Groups). Have you tried adding terms site:groups.yahoo.com inurl:flexcoders to any web search? These arguments work in both Google and Yahoo, and variants are available in other engines too. NB: From what I've seen, neither Google nor Yahoo appears to archive all messages, but this is a spidering/coverage problem rather than a problem of capability on our part. Automating a separate archive still seems like it may help, but existing archives are (at least partially) available today, through the above search tactic. For blogwork, it's possible to make an HTML field which accepts a user query, and then the Submit button adds site: and inurl arguments to this term before submitting it to the chosen search engine. Result: Visitors see a Google or Yahoo page, restricted to the FlexCoders archives, showing hits on their desired term. The first step in doing that is to get the archives. I'm not sure if Yahoo provides these, but I know how to get them otherwise. The archives are available at http://groups.yahoo.com/group/flexcoders/messages It's possible to programmatically loop through these to capture them. I'm not sure whether Yahoo Groups' Terms of Service allow for groups to harvest their own information like this. jd -- John Dowdell . Macromedia Developer Support . San Francisco CA USA Weblog: http://www.macromedia.com/go/blog_jd Aggregator: http://www.macromedia.com/go/weblogs Technotes: http://www.macromedia.com/support/ Spam killed my private email -- public record is best, thanks.
Re: [flexcoders] Making the list archives searchable
On Thu, 17 Mar 2005 11:51:18 -0800, John Dowdell [EMAIL PROTECTED] wrote: Have you tried adding terms site:groups.yahoo.com inurl:flexcoders to any web search? These arguments work in both Google and Yahoo, and variants are available in other engines too. Yes, and they don't seem to work in practice. It is a spidering/coverage problem -- they come looking and pick up whatever the latest messages at the time. I would expect Yahoo search to actually work much better with their Groups site, but it doesn't. Here's what I thought: 1. Convert the archives to mbox format using yahoo2mbox: http://www.tt-solutions.com/en/products/yahoo2mbox/ This seems to work well; I've tried it (my IP got banned for hitting the site too often :P ) 2. Create HTML site structure using hypermail: http://www.hypermail-project.org/ 3. Add search to it somehow: http://www.crispen.org/doc/hypermail/archive_search.html We may have to repeat these steps for new mail on a weekly basis. I'm not sure about the ToS though. Manish
Class path for component
I'm getting an error when I try to instantiate a component using a classpath. In my application tag, I set a class path of xmlns:mk=com.test.components. In the folder com/test/components I have the Pod.as class. When I try to create a component with: mk:Pod id=test title=Test Pod /mk:Pod I get an error: The class being compiled, 'Pod', does not match the class that was imported, 'com.test.components.Pod' This class works fine when I have it in the same directory as the app and invoke it without the classpath abbreviation. Any ideas? Thanks. - Tom
RE: [flexcoders] Class path for component
Xmlns:mk=com.test.components.* Make sure the * is there in the end. Matt From: Tom Fitzpatrick [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 2:46 PM To: [EMAIL PROTECTED] Subject: [flexcoders] Class path for component I'm getting an error when I try to instantiate a component using a classpath. In my application tag, I set a class path of xmlns:mk=com.test.components. In the folder com/test/components I have the Pod.as class. When I try to create a component with: mk:Pod id=test title=Test Pod /mk:Pod I get an error: The class being compiled, 'Pod', does not match the class that was imported, 'com.test.components.Pod' This class works fine when I have it in the same directory as the app and invoke it without the classpath abbreviation. Any ideas? Thanks. - Tom
Re: [flexcoders] TabNavigator.
How did you re-assign the dataProvider for the NavBar? I cant seem to get it to work... tabrow1.dataProvider = newdata doesnt seem to work. Gareth. On Thu, 17 Mar 2005 13:13:47 -0500, Tracy Spratt [EMAIL PROTECTED] wrote: Well, I expected selectedIndex = undefined; or selectedIndex = -1; to work but they didn't. I did discover that if you re-assign the dataProvider for the NavBar, all the tabs become un-selected. Tracy -Original Message- From: Gareth Edwards [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 1:07 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] TabNavigator. I have begun trying to get this to work. There is a fairly major issue I have come accross.. in that if I create multipul rows say I have 3.. then I have 3 tabs selected as default.. one for each row, does anyone know of a way of deselecting a tab from a tabBar? Gareth. On Tue, 8 Mar 2005 11:50:26 -0500, Tracy Spratt [EMAIL PROTECTED] wrote: Not inherently. Most Containers have a default vertical spacing that you would need to override with verticalGap=0. A TabBar in a repeater sounds like a great custom component. If you build one, please share it! Tracy -Original Message- From: Gareth Edwards [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 08, 2005 5:50 AM To: flexcoders@yahoogroups.com Subject: Re: [flexcoders] TabNavigator. Wouldnt that put a space between each tab row? On Mon, 7 Mar 2005 09:34:32 -0800, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: try using the tabBar and the repeater tag. -Art Quoting Gareth Edwards [EMAIL PROTECTED]: Unfortunately around 30 tabs is as specific as we can get at the moment. Its quite a large project with some standards that have already been put in place for multirow tabs. The DHTML versions of the controls required are finished and it would be a shame to have to write custom components to get similar functionality out of flex. Gareth. Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links
RE: [flexcoders] Class path for component
I'll take a guess that you are using Christophe's Pod.as. If that is the case, you'll need to change class definition in that file to indicate the correct package name. So instead of class Pod extends Panel it should be class com.test.components.Pod extends Panel. ActionScript classes need to be referenced with their proper package name in the class definition. Jeff Tapper blog: jeff.mxdj.com At 05:58 PM 3/17/2005, you wrote: Xmlns:mk=com.test.components.* Make sure the * is there in the end. Matt -- From: Tom Fitzpatrick [mailto:[EMAIL PROTECTED] Sent: Thursday, March 17, 2005 2:46 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Class path for component I'm getting an error when I try to instantiate a component using a classpath. In my application tag, I set a class path of xmlns:mk=com.test.components. In the folder com/test/components I have the Pod.as class. When I try to create a component with: mk:Pod id=test title=Test Pod /mk:Pod I get an error: The class being compiled, 'Pod', does not match the class that was imported, 'com.test.components.Pod' This class works fine when I have it in the same directory as the app and invoke it without the classpath abbreviation. Any ideas? Thanks. - Tom Yahoo! Groups Sponsor ADVERTISEMENT http://us.ard.yahoo.com/SIG=129mi8jta/M=298184.6191685.7192823.3001176/D=groups/S=1705007207:HM/EXP=186692/A=2593423/R=0/SIG=11el9gslf/*http://www.netflix.com/Default?mqso=60190075 click here -- Yahoo! Groups Links * To visit your group on the web, go to: * http://groups.yahoo.com/group/flexcoders/http://groups.yahoo.com/group/flexcoders/ * * To unsubscribe from this group, send an email to: * mailto:[EMAIL PROTECTED][EMAIL PROTECTED] * * Your use of Yahoo! Groups is subject to the http://docs.yahoo.com/info/terms/Yahoo! Terms of Service.