Re: [flexcoders] Experiences with XMLSocket?
It should be pointed out that the server is what you are most interested in for this case. I have had good experiences using XMLSocket and Flash in many situations. I have however seen many horrible server implementations that result in poor performance that have nothing to do with the Flash client... -- Matthew On Apr 4, 2005 6:03 PM, Ben Elmore [EMAIL PROTECTED] wrote: Eric.We are using XMLSockets in one of the engagements that I am currentlyworking on. We are in development phase at the moment and are looking to usesockets to be able to push real time status information to the client. Thegoal is to support around 2000 simultaneous connections. While the app islooking to be built in Flash for this version, Flex was fully capable inhandling this requirement. My thought would be if you abstract out yourservice calls and have the application setup with a series of respondermethods (onResult) to the XMLSocket calls you can very easily have bothstateful and stateless communication with your server to optimize you middletier interaction.You can email me off line if you like. Since we haven't deployed out to QAyet I can't specifically talk to the issues you noted below. At least notyet.Ben-Original Message-From: Eric Raymond [mailto:[EMAIL PROTECTED]]Sent: Monday, April 04, 2005 8:07 PMTo: flexcoders@yahoogroups.comSubject: [flexcoders] Experiences with XMLSocket?We are looking at using XMLSocket and a data push model to improve somereal-time aspects our application.Has anyone had real experience using XMLSOcket with a large set of users?Iguess I'm looking for cases where it doesn't work (e.g., firewall issues) ordoesn't work well.Yahoo! Groups LinksYahoo! 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/ 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.
[flexcoders] Re: Tab navigator questions ANYONE ?
Thanks alot Manish for the Tab style, that's exactly what I was looking for... About the Icon: the following mxml app have three buttons, the first one changes the icon of the first tab in a binding way, the second in a direct way, and the third allows me to control the icon's value... While both binding direct way of changing value do update icon's property, there is no visual impact of the update onscreen... Any idea on what to trigger to force icon's visual-refresh ??? Thanks, Romain ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; width=100% height=100% marginBottom=0 marginLeft=0 marginRight=0 marginTop=0 mx:Style Tab { text-align: left; } /mx:Style mx:VDividedBox width=100% height=100% mx:TabNavigator id=curTabBar width=100% height=50% tabWidth=200 historyManagement=false mx:HBox label=Client id=clientTab width=100% height=100% icon={tab1Light} marginBottom=5 marginLeft=5 marginRight=5 /mx:HBox mx:VBox label=Funds width=100% height=100% icon={tab2Light} /mx:VBox mx:VBox label=Investment width=100% height=100% icon={tab3Light} /mx:VBox /mx:TabNavigator mx:HBox width=100% mx:Button label=indirect click=tab1Light = greenLight/ mx:Button label=direct click=clientTab.icon = greenLight/ mx:Button label=show value click=alert(clientTab.icon)/ /mx:HBox /mx:VDividedBox mx:Script ![CDATA[ [Embed(source=WEB-INF/resources/images/greenlight.GIF)] private static var greenLight:String; [Embed(source=WEB-INF/resources/images/redlight.GIF)] private static var redLight:String; private var tab1Light:String = redLight; private var tab3Light:String = greenLight; ]] /mx:Script /mx:Application 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/
[flexcoders] Re: Run MXML on PC, Calling to Java on Remote Server - Help
just a few things you can do -install the samples application (samples.war) ..if you havent already. if your trying to access your java objects on websphere you probably need to use mx:RemoteObject tag with an endpoint attribute pointing to your java object e.g. mx:RemoteObject id=remote1 endpoint=http://localhost:9080/MySamples/hello.java; / the above endpoint is saying you have an application installed on your websphere called MySamples containing a hello.java (for example)]. Now you can access methods in hello.java --- In flexcoders@yahoogroups.com, Libby Chantel [EMAIL PROTECTED] wrote: Is this not doable? --- Libby Chantel [EMAIL PROTECTED] wrote: I am a newbie with Flex, trying to get it going for a proof of concept. I have Flex installed on my remote Java Server (Websphere). I can successfully make calls from Flash apps on my pc to the java programs running on the server. So far, I cannot get the very same calls from Flex to work. I cannot find an example of this setup in the MM doco for Flex. Could someone PLEASE either post a link to the doco that explains it in terms a dummy like me can understand, or, post sample MXML code that works for you? Or, maybe even do both :) Thank you very much, Libby __ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ __ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ 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/
RE: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help
Libby, Chapter 20 of Developing Rich Clients with Macromedia Flex is a free download (I posted in an earlier message) and covers in great detail the use of the RemoteObject tag, to achieve just what you are trying to do. Steven -Original Message- From: Libby Chantel [mailto:[EMAIL PROTECTED] Sent: 04 April 2005 18:59 To: flexcoders@yahoogroups.com Subject: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help I am a newbie with Flex, trying to get it going for a proof of concept. I have Flex installed on my remote Java Server (Websphere). I can successfully make calls from Flash apps on my pc to the java programs running on the server. So far, I cannot get the very same calls from Flex to work. I cannot find an example of this setup in the MM doco for Flex. Could someone PLEASE either post a link to the doco that explains it in terms a dummy like me can understand, or, post sample MXML code that works for you? Or, maybe even do both :) Thank you very much, Libby __ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ Yahoo! Groups Links -- No virus found in this incoming message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 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/
[flexcoders] Re: Problem with showBusyCursor on a popupWindow
Matt, With FB debugger I can catch this each time I try to close the titleWindow. The problem is that the method in question does not exist in my component. Remote Object Method: cfcs.core.tab_suport.substr Parameter 1: name : param1 type : number value : 0 Parameter 2: name : param2 type : number value : 2 Message Target : cfcs.core.tab_suport.substr data[array] : length[Number] : 2 [0][Number] : 0 [1][Number] : 2 Regards, João Fernandes In flexcoders@yahoogroups.com, Matt Chotin [EMAIL PROTECTED] wrote: Do you know what method it's trying to call? I suppose the window could be introspecting the contained objects but that would be weird. A workaround would maybe be to move the RemoteObject outside the TitleWindow into another class and simply have your functions call the outside remote object. Matt _ From: joao_m_fernandes [mailto:[EMAIL PROTECTED] Sent: Monday, April 04, 2005 6:27 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Problem with showBusyCursor on a popupWindow Hi there, I'm calling a RemoteObject method inside a popup with showbusycursor enabled. The problem is when I call click function to delete the popup, the busy cursor shows up calling some remote meth od that I don't use anywhere (got that from FB network debugger). If I remove showbusycursor property it works just fine. Is this an known issue? ?xml version=1.0 encoding=utf-8? mx:TitleWindow xmlns:mx=http://www.macromedia.com/2003/mxml http://www.macromedia.com/2003/mxml title=Adicionar Contacto xmlns=* initialize=initApli() click=this.deletePopUp() mx:RemoteObject id=tab_ro endpoint=/cfusion/flashservices/gateway source=cfcs.core.tab_suport showBusyCursor=true mx:method name=GetPais result=setDefaultPais()/ mx:method name=GetHabilitacao/ /mx:RemoteObject ... João Fernandes _ 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: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] * Your use of Yahoo! Groups is subject to the Yahoo! http://docs.yahoo.com/info/terms/ Terms of Service. 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/
[flexcoders] Bug report: Incorrect hidden member in ancestor class warnings
Hi all, Sorry I haven't had the chance to report this sooner but it appears that Flex issues incorrect warnings when you extend the core Application and/or Form classes and try to reference a component both in MXML and AS. Case in point: // ArpPizza.mxml pizzaView:Application xmlns:pizzaView=com.ariaware.pizza.view.* xmlns:mxml=* xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundImage=@Embed('Graphics/design.gif') // ... mx:Canvas width=550 height=400 mx:LinkBar id=linkBar x=360 y=14 / mx:ViewStack id=screens x=38 y=59 mxml:OrderForm id=orderForm label=Order Form / mxml:ViewOrdersForm id=viewOrdersForm label=View Orders / /mx:ViewStack // ... Note: ViewStack contains the two forms with ids set to orderForm and viewOrdersForm. class com.ariaware.pizza.view.Application extends mx.core.Application { // // On stage // private var screens:mx.containers.ViewStack; private var linkBar:mx.containers.LinkBar; private var orderForm:OrderForm; private var viewOrdersForm:ViewOrdersForm; private var dataPreloader:ProgressBar; // etc. * * * Actual behavior: 4 Warnings found. Warning /ArpPizza.mxml:22 The member, viewOrdersForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:21 The member, orderForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:22 The member, viewOrdersForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:21 The member, orderForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. * * * Expected behavior: No warnings should be given as we are not hiding a member (we are simply referring to the same member, once in MXML and once in AS2.) This is exactly what we do in Flash when we give a component an instance name and then declare it in the form's class. I know the Flex MM team frequent this forum so I thought I'd send this over here. If you need the full app to test with, just let me know. Thanks, Aral 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/
RE: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings
Hi Aral, This doesn't look like a bug to me. You are effectively creating a sub-class with the same class members as its base class contains (set the keep-generated flag when you compile and you'll see that) and the Flex compiler is correctly warning you of that. Taking MXML out of the equation (and simplified), here's what you're really doing: class com.ariaware.pizza.view.Application extends mx.core.Application { ... private var orderForm:OrderForm; ... class AprPizza extends com.ariaware.pizza.view.Application { ... public var orderForm:OrderForm; ... So, you are hiding the base class member. Is there really a need to have the same class members in both the base class and the sub-class? If you explain what you're trying to do, we may be able to offer alternatives. Cheers, Ali -- Alistair McLeod Development Director iteration::two [EMAIL PROTECTED] Office: +44 (0)131 338 6108 Mobile: +44 (0)7976 987252 This e-mail and any associated attachments transmitted with it may contain confidential information and must not be copied, or disclosed, or used by anyone other than the intended recipient(s). If you are not the intended recipient(s) please destroy this e-mail, and any copies of it, immediately. Please also note that while software systems have been used to try to ensure that this e-mail has been swept for viruses, iteration::two do not accept responsibility for any damage or loss caused in respect of any viruses transmitted by the e-mail. Please ensure your own checks are carried out before any attachments are opened. -Original Message- From: Aral Balkan [mailto:[EMAIL PROTECTED] Sent: 05 April 2005 12:54 To: flexcoders@yahoogroups.com Subject: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings Hi all, Sorry I haven't had the chance to report this sooner but it appears that Flex issues incorrect warnings when you extend the core Application and/or Form classes and try to reference a component both in MXML and AS. Case in point: // ArpPizza.mxml pizzaView:Application xmlns:pizzaView=com.ariaware.pizza.view.* xmlns:mxml=* xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundImage=@Embed('Graphics/design.gif') // ... mx:Canvas width=550 height=400 mx:LinkBar id=linkBar x=360 y=14 / mx:ViewStack id=screens x=38 y=59 mxml:OrderForm id=orderForm label=Order Form / mxml:ViewOrdersForm id=viewOrdersForm label=View Orders / /mx:ViewStack // ... Note: ViewStack contains the two forms with ids set to orderForm and viewOrdersForm. class com.ariaware.pizza.view.Application extends mx.core.Application { // // On stage // private var screens:mx.containers.ViewStack; private var linkBar:mx.containers.LinkBar; private var orderForm:OrderForm; private var viewOrdersForm:ViewOrdersForm; private var dataPreloader:ProgressBar; // etc. * * * Actual behavior: 4 Warnings found. Warning /ArpPizza.mxml:22 The member, viewOrdersForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:21 The member, orderForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:22 The member, viewOrdersForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:21 The member, orderForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. * * * Expected behavior: No warnings should be given as we are not hiding a member (we are simply referring to the same member, once in MXML and once in AS2.) This is exactly what we do in Flash when we give a component an instance name and then declare it in the form's class. I know the Flex MM team frequent this forum so I thought I'd send this over here. If you need the full app to test with, just let me know. Thanks, Aral Yahoo! Groups Links 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/
Re: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings
Hi Ali, Actually, your email highlights the problem even better than mine :) The problem currently is exactly as you illustrate. I am being forced to write the equivalent of the code you provided (below) because Flex does not understand that orderForm already exists in the base class and redeclares it while compiling the MXML. // Ali's code demonstrating bug in question class com.ariaware.pizza.view.Application extends mx.core.Application { ... private var orderForm:OrderForm; ... class AprPizza extends com.ariaware.pizza.view.Application { ... public var orderForm:OrderForm; ... Of course, the ideal thing would be to fix this behavior so that the compiler does not redeclare properties that already exist in the base classes. This is the same issue I was pointing out (albeit starting with the symptom and not the cause.) Thus, Flex should generate the following code, but doesn't: // How Flex *should* generate the class class com.ariaware.pizza.view.Application extends mx.core.Application { ... private var orderForm:OrderForm; ... class AprPizza extends com.ariaware.pizza.view.Application { ... // public var orderForm:OrderForm; // Not redeclared because it already exists in base class. ... Not knowing the amount of work that would be involved to fix the actual cause, I was suggesting it might be easier to turn off the warning message in these instances. As I stated earlier, however, it would be ideal if Flex detected the existence of the property in the base class and didn't redeclare it when creating the AS2 class from the MXML. All the best, Aral Alistair McLeod wrote: Hi Aral, This doesn't look like a bug to me. You are effectively creating a sub-class with the same class members as its base class contains (set the keep-generated flag when you compile and you'll see that) and the Flex compiler is correctly warning you of that. Taking MXML out of the equation (and simplified), here's what you're really doing: class com.ariaware.pizza.view.Application extends mx.core.Application { ... private var orderForm:OrderForm; ... class AprPizza extends com.ariaware.pizza.view.Application { ... public var orderForm:OrderForm; ... So, you are hiding the base class member. Is there really a need to have the same class members in both the base class and the sub-class? If you explain what you're trying to do, we may be able to offer alternatives. Cheers, Ali -- Alistair McLeod Development Director iteration::two [EMAIL PROTECTED] Office: +44 (0)131 338 6108 Mobile: +44 (0)7976 987252 This e-mail and any associated attachments transmitted with it may contain confidential information and must not be copied, or disclosed, or used by anyone other than the intended recipient(s). If you are not the intended recipient(s) please destroy this e-mail, and any copies of it, immediately. Please also note that while software systems have been used to try to ensure that this e-mail has been swept for viruses, iteration::two do not accept responsibility for any damage or loss caused in respect of any viruses transmitted by the e-mail. Please ensure your own checks are carried out before any attachments are opened. -Original Message- From: Aral Balkan [mailto:[EMAIL PROTECTED] Sent: 05 April 2005 12:54 To: flexcoders@yahoogroups.com Subject: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings Hi all, Sorry I haven't had the chance to report this sooner but it appears that Flex issues incorrect warnings when you extend the core Application and/or Form classes and try to reference a component both in MXML and AS. Case in point: // ArpPizza.mxml pizzaView:Application xmlns:pizzaView=com.ariaware.pizza.view.* xmlns:mxml=* xmlns:mx=http://www.macromedia.com/2003/mxml; backgroundImage=@Embed('Graphics/design.gif') // ... mx:Canvas width=550 height=400 mx:LinkBar id=linkBar x=360 y=14 / mx:ViewStack id=screens x=38 y=59 mxml:OrderForm id=orderForm label=Order Form / mxml:ViewOrdersForm id=viewOrdersForm label=View Orders / /mx:ViewStack // ... Note: ViewStack contains the two forms with ids set to orderForm and viewOrdersForm. class com.ariaware.pizza.view.Application extends mx.core.Application { // // On stage // private var screens:mx.containers.ViewStack; private var linkBar:mx.containers.LinkBar; private var orderForm:OrderForm; private var viewOrdersForm:ViewOrdersForm; private var dataPreloader:ProgressBar; // etc. * * * Actual behavior: 4 Warnings found. Warning /ArpPizza.mxml:22 The member, viewOrdersForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning /ArpPizza.mxml:21 The member, orderForm, hides a member in ancestor class, 'com.ariaware.pizza.view.Application'. Warning
Re: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings
On Apr 5, 2005 6:15 PM, Aral Balkan [EMAIL PROTECTED] wrote: The problem currently is exactly as you illustrate. I am being forced to write the equivalent of the code you provided (below) because Flex does not understand that orderForm already exists in the base class and redeclares it while compiling the MXML. Seems like there might be a quick way to get around this: mx:ViewStack initialize=screens = event.target x=38 y=59 See the initialize handler. s/id=\([^]\+\)/initialize=\1 = event.target/g Manish 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/
RE: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings
Manish, s/id=\([^]\+\)/initialize=\1 = event.target/g You're coding MXML in vi ? ;-) Steven :wq! -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 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/
[flexcoders] Remote object that returns an array of objects
All, I have a method on my app server called getAllUser() that returns UserVO[]. When I get that back in flex as an Array the items inside the array are of type object, instead of the actionScript UserVO that is associated with that java type being returned. My work around for this is to create a UserArrayVO class on both sides (App Server and Flex) and in that class is just one variable that is of type UserVO[] on the server and Array on flex and then I get back the correct classes in flex. So my question is, is this the way to do something like this? Obviously flex knows how to handle the objects when it is within another class, just not when it is an array of them coming back. Thanks Jeff 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] Bug report: Incorrect hidden member in ancestor class warnings
On Apr 5, 2005 8:37 PM, Steven Webster [EMAIL PROTECTED] wrote: s/id=\([^]\+\)/initialize=\1 = event.target/g You're coding MXML in vi ? ;-) Totally, Steven! I use Vim. The secret of my energy. ;-) Excerpts from my vimrc file: autocmd BufRead *.mxml set filetype=xml foldmethod=indent if has(autocmd) XML autocmd FileType xml set noet ts=2 sw=2 tw=79 autocmd FileType xml imap ,xml ?xml version=1.0? begin MXML-specific autocmd BufRead *.mxml imap ,app mx:Application xmlns:mx=http://www.macromedia.com/2003/mxml; xmlns=* autocmd BufRead *.mxml imap ,ti mx:TextInput id= autocmd BufRead *.mxml imap ,btn mx:Button label= autocmd BufRead *.mxml imap ,scr mx:Script autocmd BufRead *.mxml imap ,sty mx:Style autocmd BufRead *.mxml imap ,dp dataProvider= autocmd BufRead *.mxml imap ,vb mx:VBox autocmd BufRead *.mxml imap ,hb mx:HBox autocmd BufRead *.mxml imap ,vs mx:ViewStack end MXML-specific endif Should probably add more now since I've learnt so much MXML. :) Manish 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/
RE: [flexcoders] Remote object that returns an array of objects
Are you using Object.registerClass() to register the UserVO type to map the fully qualified ActionScript class name to that returned by Java (rather than the old Flex 1.0 _remoteClass which I strongly discourage in Flex 1.5)? If so, then the next step is verify that the server sent back Typed AMF Objects in the RemoteObject response rather than generic AMF Objects. To do so, you want to rely on server side logging for this as it is more reliable and client AMF debugging tools (notably it avoids the issue in the old Flash Remoting NetConnection Debugger where by registered objects are printed as "undefined" in the trace output - possibly related to a bug in AS2 that registered type instances answer true to a test for "== null"...the work around to this bug in your own code isto use the strictequality test of "=== null" or "!== null") If you're working on a local Flex server and launched your app server on the command line - enable console logging in /WEB-INF/flex/flex-config.xml and then modify the AMF Gateway logging settings by turning on "Debug" level logging in the /WEB-INF/flex/gateway-config.xml file. You should see in AMF trace whether Typed objects were sent (and the classname that was specified for the type). From: Jeff Krueger [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 11:47 AMTo: flexcoders@yahoogroups.comSubject: [flexcoders] Remote object that returns an array of objects All, I have a method on my app server called getAllUser() that returns UserVO[]. When I get that back in flex as an Array the items inside the array are of type object, instead of the actionScript UserVO that is associated with that java type being returned. My work around for this is to create a UserArrayVO class on both sides (App Server and Flex) and in that class is just one variable that is of type UserVO[] on the server and Array on flex and then I get back the correct classes in flex. So my question is, is this the way to do something like this? Obviously flex knows how to handle the objects when it is within another class, just not when it is an array of them coming back. Thanks Jeff 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] Remote object that returns an array of objects
Hi Jeff, You don't mention if you are using the Cairngorm frameworkor not, but I do and I also use ValueObjects. I took the ViewHelper/ViewLocator pattern and created a ValueObject (or Model) Pattern so that finding ValueObjects from anywhere in your app is as easy as the ViewHelper pattern. If I understand your question correctly its the same thing that I do - wrapping a single array of VOs within a VO. Not be a master of programming patterns and methodologies, I too would be interested in knowing if this is a good solution for our situations. Regards, Simon Fifield -Original Message-From: Jeff Krueger [mailto:[EMAIL PROTECTED]Sent: 05 April 2005 16:47To: flexcoders@yahoogroups.comSubject: [flexcoders] Remote object that returns an array of objects All, I have a method on my app server called getAllUser() that returns UserVO[]. When I get that back in flex as an Array the items inside the array are of type object, instead of the actionScript UserVO that is associated with that java type being returned. My work around for this is to create a UserArrayVO class on both sides (App Server and Flex) and in that class is just one variable that is of type UserVO[] on the server and Array on flex and then I get back the correct classes in flex. So my question is, is this the way to do something like this? Obviously flex knows how to handle the objects when it is within another class, just not when it is an array of them coming back. Thanks Jeff 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] Run MXML on PC, Calling to Java on Remote Server - Help
I read your chapter but it didn't explain how to do what I am trying to do. I think my favorite part was on page 5, where it says: ... if youre implementing an RIA interface on an existing J2EE infrastructure that has business logic contained in your Servlet tier, consult the Flex documentation to see how you can use RemoteObject to invoke methods exposed on Servlets in your app server. That note was particularly helpful sarcasm in light of the fact I can't find any such info so far in the MM documentation. Eventually I will figure out exactly where to look, I'm sure. So far I can find tidbits, but no examples, of how to write mxml on one machine in flexbuilder, then run it from flexbuilder to invoke java on a remote app server, as if it were a client-server app. Libby --- Steven Webster [EMAIL PROTECTED] wrote: Libby, Chapter 20 of Developing Rich Clients with Macromedia Flex is a free download (I posted in an earlier message) and covers in great detail the use of the RemoteObject tag, to achieve just what you are trying to do. Steven -Original Message- From: Libby Chantel [mailto:[EMAIL PROTECTED] Sent: 04 April 2005 18:59 To: flexcoders@yahoogroups.com Subject: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help I am a newbie with Flex, trying to get it going for a proof of concept. I have Flex installed on my remote Java Server (Websphere). I can successfully make calls from Flash apps on my pc to the java programs running on the server. So far, I cannot get the very same calls from Flex to work. I cannot find an example of this setup in the MM doco for Flex. Could someone PLEASE either post a link to the doco that explains it in terms a dummy like me can understand, or, post sample MXML code that works for you? Or, maybe even do both :) Thank you very much, Libby __ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ Yahoo! Groups Links -- No virus found in this incoming message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 Yahoo! Groups Links [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.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/
RE: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help
Hi Libby, I'm no J2EE expert and I do not use servlets with Flex, but I do use RemoteObjects. Can't you instantiate your servlet from a Java RemoteObject and call the servlets methods from within the RemoteObject? Regards, Simon Fifield -Original Message- From: Libby Chantel [mailto:[EMAIL PROTECTED] Sent: 05 April 2005 17:55 To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help I read your chapter but it didn't explain how to do what I am trying to do. I think my favorite part was on page 5, where it says: ... if youre implementing an RIA interface on an existing J2EE infrastructure that has business logic contained in your Servlet tier, consult the Flex documentation to see how you can use RemoteObject to invoke methods exposed on Servlets in your app server. That note was particularly helpful sarcasm in light of the fact I can't find any such info so far in the MM documentation. Eventually I will figure out exactly where to look, I'm sure. So far I can find tidbits, but no examples, of how to write mxml on one machine in flexbuilder, then run it from flexbuilder to invoke java on a remote app server, as if it were a client-server app. Libby --- Steven Webster [EMAIL PROTECTED] wrote: Libby, Chapter 20 of Developing Rich Clients with Macromedia Flex is a free download (I posted in an earlier message) and covers in great detail the use of the RemoteObject tag, to achieve just what you are trying to do. Steven -Original Message- From: Libby Chantel [mailto:[EMAIL PROTECTED] Sent: 04 April 2005 18:59 To: flexcoders@yahoogroups.com Subject: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help I am a newbie with Flex, trying to get it going for a proof of concept. I have Flex installed on my remote Java Server (Websphere). I can successfully make calls from Flash apps on my pc to the java programs running on the server. So far, I cannot get the very same calls from Flex to work. I cannot find an example of this setup in the MM doco for Flex. Could someone PLEASE either post a link to the doco that explains it in terms a dummy like me can understand, or, post sample MXML code that works for you? Or, maybe even do both :) Thank you very much, Libby __ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ Yahoo! Groups Links -- No virus found in this incoming message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 Yahoo! Groups Links [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com Yahoo! Groups Links 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/
RE: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help
I'm still not sure how far you have gotten and where you are stuck. Have you run the RemoteObject example in the samples folder? I also posted a simple example that extends the example: http://www.cflex.net/showfiledetails.cfm?ChannelID=1Object=FileobjectI D=18 Now both those examples use a remote service on a local machine. Can you do that ok? Is your problem specifically with the remote server? Have you set up the whitelist? Do you get any errors? Tracy -Original Message- From: Libby Chantel [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 12:55 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help I read your chapter but it didn't explain how to do what I am trying to do. I think my favorite part was on page 5, where it says: ... if you're implementing an RIA interface on an existing J2EE infrastructure that has business logic contained in your Servlet tier, consult the Flex documentation to see how you can use RemoteObject to invoke methods exposed on Servlets in your app server. That note was particularly helpful sarcasm in light of the fact I can't find any such info so far in the MM documentation. Eventually I will figure out exactly where to look, I'm sure. So far I can find tidbits, but no examples, of how to write mxml on one machine in flexbuilder, then run it from flexbuilder to invoke java on a remote app server, as if it were a client-server app. Libby --- Steven Webster [EMAIL PROTECTED] wrote: Libby, Chapter 20 of Developing Rich Clients with Macromedia Flex is a free download (I posted in an earlier message) and covers in great detail the use of the RemoteObject tag, to achieve just what you are trying to do. Steven -Original Message- From: Libby Chantel [mailto:[EMAIL PROTECTED] Sent: 04 April 2005 18:59 To: flexcoders@yahoogroups.com Subject: [flexcoders] Run MXML on PC, Calling to Java on Remote Server - Help I am a newbie with Flex, trying to get it going for a proof of concept. I have Flex installed on my remote Java Server (Websphere). I can successfully make calls from Flash apps on my pc to the java programs running on the server. So far, I cannot get the very same calls from Flex to work. I cannot find an example of this setup in the MM doco for Flex. Could someone PLEASE either post a link to the doco that explains it in terms a dummy like me can understand, or, post sample MXML code that works for you? Or, maybe even do both :) Thank you very much, Libby __ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ Yahoo! Groups Links -- No virus found in this incoming message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.2 - Release Date: 05/04/2005 Yahoo! Groups Links [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com Yahoo! Groups Links 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/
[flexcoders] PopUp Help!
Greetings All, I have been looking for some pop up example code online and have not found much so far. For example, I have a form item of airport code. The user should be able to initiate a popup search to look for said code by city, country, airport name, etc. Then select the apporpirate code and have the form item populated. Any help/example code would be much appreciated. Thanks, Jeff 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/
[flexcoders] Data Grid and cell renderer
I'm using a simple DateField as the CellRenderer of a column in my DataGrid. Clicking in the cell with the mouse brings up the date picker ,allowing me to select a date, but tabbing through the grid brings up a textinput without the date information already entered by the date picker. Is there a way to not display the text input, allowing the user only the ability to use the DateField? Thanks 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/
[flexcoders] XMLNode CDATA
Hi, I am writing an XML decoder for my HTTPService, and noticed that the nodeValue is a null when I have a CDATA element. How do I get the CDATA value from the XMLNode? Thanks. - viraf 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/
RE: [flexcoders] Remote object that returns an array of objects
Simon, Hi I am using the Cairngorm framework. My problem is not in finding a value object in the code as much as getting an array of object back form the server. But thanks for the information. Jeff From: Simon Fifield [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 10:00 AM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects Hi Jeff, You don't mention if you are using the Cairngorm frameworkor not, but I do and I also use ValueObjects. I took the ViewHelper/ViewLocator pattern and created a ValueObject (or Model) Pattern so that finding ValueObjects from anywhere in your app is as easy as the ViewHelper pattern. If I understand your question correctly its the same thing that I do - wrapping a single array of VOs within a VO. Not be a master of programming patterns and methodologies, I too would be interested in knowing if this is a good solution for our situations. Regards, Simon Fifield -Original Message- From: Jeff Krueger [mailto:[EMAIL PROTECTED] Sent: 05 April 2005 16:47 To: flexcoders@yahoogroups.com Subject: [flexcoders] Remote object that returns an array of objects All, I have a method on my app server called getAllUser() that returns UserVO[]. When I get that back in flex as an Array the items inside the array are of type object, instead of the actionScript UserVO that is associated with that java type being returned. My work around for this is to create a UserArrayVO class on both sides (App Server and Flex) and in that class is just one variable that is of type UserVO[] on the server and Array on flex and then I get back the correct classes in flex. So my question is, is this the way to do something like this? Obviously flex knows how to handle the objects when it is within another class, just not when it is an array of them coming back. Thanks Jeff 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] Simple Cairngorm architecture question
Maybe I don't fully understand the question. But it seems that you would broadcast the DeleteGroup event only once the click of ok was pressed. The broadcast will find the command to do the work and then notify the view helper when done. Jeff -Original Message- From: cazzaran [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 2:13 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Simple Cairngorm architecture question I have a simple architectural philosophy question regarding Cairngorm. I am using the Contoller, Command, and ViewHelper pattern, which is working out perfectly -- except in one situation... And it's not that I can't get this to work, it's that I'm curious what the proper way to do it would be. I have a delete button that allows my users to delete a Group out of a list. The issue is that I need to provide an Alert box with a OK/Cancel buttons. This alert box needs to be given a listener object with a click() method. My question is where does this belong? In the MXML that shows the Delete button, the DeleteGroupCommand, the ViewHelper associated with the view, or somewhere else entirely? This is a kind of hiccup in the whole Controller to Command flow... Yahoo! Groups Links 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/
Re: [flexcoders] Re: Tab navigator questions ANYONE ?
On Apr 5, 2005 12:35 PM, r0main [EMAIL PROTECTED] wrote: While both binding direct way of changing value do update icon's property, there is no visual impact of the update onscreen... Any idea on what to trigger to force icon's visual-refresh ??? Seems like the tabs are updated only once when the TabBar is created. You could do one of the following: 1. Reset the Tab object's icon property manually. 2. Reset the TabBar's dataProvider to itself (will cause the Tab objects to get recreated). You can grap the TabBar inside the TabNavigator using the private tabBar property (some ActionScript cheating). tabNavigator['tabBar'].getChildAt(0).icon = newIcon; Manish 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/
Re: [flexcoders] Re: PopUp Help!
On Apr 6, 2005 1:53 AM, Jeff [EMAIL PROTECTED] wrote: Sure, although there is not much to my code in terms of what I want to do with a popup. You want to use a TitleWindow. Search the arcihved for TitleWindow... there's tons of code examples: http://www.mail-archive.com/cgi-bin/htsearch?config=flexcoders_yahoogroups_comwords=titlewindow Manish 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/
[flexcoders] Re: XMLNode CDATA
Thanks - I will try this. Is there any documentation (except in the ActionScript manual describing the XML class) that defines the rules as to when to use nodeValue vs firstChild. - viraf --- In flexcoders@yahoogroups.com, JesterXL [EMAIL PROTECTED] wrote: Try firstChild.firstChild instead of firstChild.nodeValue. - Original Message - From: viraf_bankwalla [EMAIL PROTECTED] To: flexcoders@yahoogroups.com Sent: Tuesday, April 05, 2005 3:40 PM Subject: [flexcoders] XMLNode CDATA Hi, I am writing an XML decoder for my HTTPService, and noticed that the nodeValue is a null when I have a CDATA element. How do I get the CDATA value from the XMLNode? Thanks. - viraf Yahoo! Groups Links 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/
RE: [flexcoders] Re: Simple Cairngorm architecture question
Why do you have to only have one click method? You can use the Delegate class to redirect each event to a difrent method. Omar Ramos Itacon Corporation Technology Manager From: cazzaran [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 4:34 PMTo: flexcoders@yahoogroups.comSubject: [flexcoders] Re: Simple Cairngorm architecture question You're right. My question, is where should I put the click() thatkicks off the event. I COULD put it in the MXML, and just have theview capture the click from the Alert and then broadcast the event,but a problem occurs once I have more than one button that needs tohave an Alert attached; I can only have one click(). So now I need tofind a place to put a click() for each Alert box... is the right placeinside the Command class for each button's function?-Josh--- In flexcoders@yahoogroups.com, "Jeff Krueger" [EMAIL PROTECTED] wrote: Maybe I don't fully understand the question. But it seems that youwould broadcast the "DeleteGroup" event only once the click of ok was pressed. The broadcast will find the command to do the work and then notifythe view helper when done. Jeff -Original Message- From: cazzaran [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 2:13 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Simple Cairngorm architecture question I have a simple architectural philosophy question regarding Cairngorm. I am using the Contoller, Command, and ViewHelper pattern, which is working out perfectly -- except in one situation... And it's not that I can't get this to work, it's that I'm curious what the proper way to do it would be. I have a delete button that allows my users to delete a Group out of a list. The issue is that I need to provide an Alert box with a OK/Cancel buttons. This alert box needs to be given a listener object with a click() method. My question is where does this belong? In the MXML that shows the Delete button, the DeleteGroupCommand, the ViewHelper associated with the view, or somewhere else entirely? This is a kind of hiccup in the whole Controller to Command flow... Yahoo! Groups Links 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.
[flexcoders] ViewStack children instance
I know this is a simple question that maybe has been posted many times, but I cound't find an answer so... I have a viewStack container and I want to prepopulate one view before displaying it. How can I do that? Thanks, Valy Do you Yahoo!? Better first dates. More second dates. Yahoo! Personals 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] Remote object that returns an array of objects
Hi Jeff, I do exactly what you are doing in Test 2, I duplicated this pattern from the Login example of the Cairngorm framework files. If you find a better way, let me know because it does add unnecessary extra work to wrap an extra value object around your array when that's all you want back from the server. Regards, Simon Fifield -Original Message-From: Jeff Krueger [mailto:[EMAIL PROTECTED]Sent: 05 April 2005 21:56To: flexcoders@yahoogroups.comSubject: RE: [flexcoders] Remote object that returns an array of objectsI use the UserVO within script in the application, not in the exact script,but in other places. I was doing an alert with the typeof function. I don't have a function butI do have lots of public vars which come back undefined. So I assume theywere not of the proper type.I think I have a test case that should prove the class is available but I amnot sure. I am using the cairngorm framework. So in my command class inthe onResult class I can test these two sets of code. Obviously I switchout the java code to return the correct types to match the test.Test 1 (Fails, but I do get the correct length array of 1 item)var tempArray:Array = Array (event.result);for (var i = 0; itempArray.length; i++){ var tempUser:UserVO = UserVO(tempArray[i]); mx.core.Application.alert ("Test with userVo " + tempUser.userName);}Test 2 (Succeeds)var temp:UserArrayVO = UserArrayVO (event.result);var tempUser:UserVO = UserVO(temp.userArray[0]);mx.core.Application.alert ("Test2 with userVo " + tempUser.userName);Does that test make any sense or prove or disprove anything?ThanksJeff-Original Message-From: Peter Farland [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 2:15 PMTo: flexcoders@yahoogroups.comSubject: RE: [flexcoders] Remote object that returns an array of objects[snip]Info: Serializing response (Message #0 targetURI=/2/onResult, responseURI=null) (Array #0) [0] = (Typed Object #1 'net.crownmedia.flex.user.vo.UserVO')[/snip]The AMF trace says objects are being sent back as Typed AMF Objects inboth cases... so now you have to determine whether the type is linked inat compile time (this will depend on more than just an import statement- you actually have to use the type somewhere in the script) so that itis available at runtime.When you said "the items inside the array are of type object" how areyou determining that they are just a plain old ActionScript object? Notethat typeof() in AS2 does not tell you the class name of an instance, italways says object for anything that is derived from object. Do you have a function on your ActionScript UserVO class that you cancall to check whether it was correctly instantiated as UserVO?Yahoo! Groups Links 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.
[flexcoders] Re: Simple Cairngorm architecture question
If you looks at the mx.controls.Alert class, you can only give the show() method a listener object, and that object must implement a click() method. You can't specify which method the Alert may call, so I'm stuck giving it an object that has one click(). If this object happens to be the MXML, then I can't use it for different Alerts, because each one will only call click(). So now I have to decide where the proper place for click() should be. I don't want to use groupdetails.mxml, for the reason stated above (I also have buttons that deactivate groups, and do other things, all backed by Alerts). I don't know if it should go into the DeleteGroupCommand. I supposed I could add a click() method to this command, that kicks off an event that runs the same command, but that seems messy. It also somewhat ties my command to my view, since the Alert is just a UI technicality. This leaves the GroupDetailsViewHelper, but again, using this class for broadcasting a command event might not be right. Thoughts? -Josh --- In flexcoders@yahoogroups.com, Omar Ramos [EMAIL PROTECTED] wrote: Why do you have to only have one click method? You can use the Delegate class to redirect each event to a difrent method. Omar Ramos Itacon Corporation Technology Manager _ From: cazzaran [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 4:34 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: Simple Cairngorm architecture question You're right. My question, is where should I put the click() that kicks off the event. I COULD put it in the MXML, and just have the view capture the click from the Alert and then broadcast the event, but a problem occurs once I have more than one button that needs to have an Alert attached; I can only have one click(). So now I need to find a place to put a click() for each Alert box... is the right place inside the Command class for each button's function? -Josh --- In flexcoders@yahoogroups.com, Jeff Krueger [EMAIL PROTECTED] wrote: Maybe I don't fully understand the question. But it seems that you would broadcast the DeleteGroup event only once the click of ok was pressed. The broadcast will find the command to do the work and then notify the view helper when done. Jeff -Original Message- From: cazzaran [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 2:13 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Simple Cairngorm architecture question I have a simple architectural philosophy question regarding Cairngorm. I am using the Contoller, Command, and ViewHelper pattern, which is working out perfectly -- except in one situation... And it's not that I can't get this to work, it's that I'm curious what the proper way to do it would be. I have a delete button that allows my users to delete a Group out of a list. The issue is that I need to provide an Alert box with a OK/Cancel buttons. This alert box needs to be given a listener object with a click() method. My question is where does this belong? In the MXML that shows the Delete button, the DeleteGroupCommand, the ViewHelper associated with the view, or somewhere else entirely? This is a kind of hiccup in the whole Controller to Command flow... Yahoo! Groups Links _ 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/ . 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/
RE: [flexcoders] Remote object that returns an array of objects
I don't really do anything in my constructor. I use to set the _remoteClass. class net.crownmedia.flex.vo.user.UserVO { public static var SUCCESFULSTATUS:String = APPROVED; public function UserVO() { // _remoteClass = net.crownmedia.flex.user.vo.UserVO; } public var _remoteClass : String; public var userProfileId:String; public var personId:String; public var userName:String; public var password:String; public var status:String; public var person:PersonVO; public var timeZone:TimeZoneVO; public var application:ApplicationVO; public var securityKeys:Array; private static var doRegister:Boolean = Object.registerClass( net.crownmedia.flex.user.vo.UserVO, UserVO ); } -Original Message- From: Peter Farland [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 3:04 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects Can you show me the constructor of your ActionScript UserVO class? Note that ActionScript object instantiation from deserialized AMF is different from, say, normal Java object instantiation. i.e. The ActionScript pseudo code might look something like this (note, I'm not an AS coder and this isn't real ActionScript... just a reflection of my understanding of what goes on): var myInstance:MyType = MyType.prototype.clone(); myInstance.someProperty = suppliedValue; myInstance.anotherProperty = anotherSuppliedValue; ... myInstance.constructor(); This allows you to mimic passing constructor arguments. If you set defaults in your constructor then you should first check to see if a property is undefined so that you don't override the deserialized value. -Original Message- From: Jeff Krueger [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 4:56 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects I use the UserVO within script in the application, not in the exact script, but in other places. I was doing an alert with the typeof function. I don't have a function but I do have lots of public vars which come back undefined. So I assume they were not of the proper type. I think I have a test case that should prove the class is available but I am not sure. I am using the cairngorm framework. So in my command class in the onResult class I can test these two sets of code. Obviously I switch out the java code to return the correct types to match the test. Test 1 (Fails, but I do get the correct length array of 1 item) var tempArray:Array = Array (event.result); for (var i = 0; itempArray.length; i++) { var tempUser:UserVO = UserVO(tempArray[i]); mx.core.Application.alert (Test with userVo + tempUser.userName); } Test 2 (Succeeds) var temp:UserArrayVO = UserArrayVO (event.result); var tempUser:UserVO = UserVO(temp.userArray[0]); mx.core.Application.alert (Test2 with userVo + tempUser.userName); Does that test make any sense or prove or disprove anything? Thanks Jeff -Original Message- From: Peter Farland [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 2:15 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects [snip] Info: Serializing response (Message #0 targetURI=/2/onResult, responseURI=null) (Array #0) [0] = (Typed Object #1 'net.crownmedia.flex.user.vo.UserVO') [/snip] The AMF trace says objects are being sent back as Typed AMF Objects in both cases... so now you have to determine whether the type is linked in at compile time (this will depend on more than just an import statement - you actually have to use the type somewhere in the script) so that it is available at runtime. When you said the items inside the array are of type object how are you determining that they are just a plain old ActionScript object? Note that typeof() in AS2 does not tell you the class name of an instance, it always says object for anything that is derived from object. Do you have a function on your ActionScript UserVO class that you can call to check whether it was correctly instantiated as UserVO? Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links 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/
Re: [flexcoders] ViewStack children instance
On Apr 6, 2005 2:14 AM, Valy Sivec [EMAIL PROTECTED] wrote: I have a viewStack container and I want to prepopulate one view before displaying it. How can I do that? Quick answer: In the initialization phase (initialize handler), switch the selectedIndex to the index of that view which you want loaded, and then switch back in creationComplete. Yeah... I guess. Try it out. Okay, on second thoughts, that sounds lame. Why not add the views dynamically using createChild(). So add two views in your MXML and have creationPolicy=all. Then add more views as you need 'em. Manish 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/
RE: [flexcoders] Remote object that returns an array of objects
Just curious, what does: mx.core.Application.alert (Test with userVo + event.result[0].userName); do? 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/
Re: [flexcoders] Bug report: Incorrect hidden member in ancestor class warnings
On Apr 6, 2005 2:55 AM, Aral Balkan [EMAIL PROTECTED] wrote: I do hope that the Flex team can get around to fixing this for the next release. Thanks for reporting this and giving your opinion as well, Aral. Manish 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/
RE: [flexcoders] Remote object that returns an array of objects
Hm, that worked! Here is the log, not sure if it shows anything. Any idea how I can get that to an object? Jeff Info: Completed 'net.crownmedia.flex.user.FlexUserDelegate.getAll' with reply me thod 'onResult' in 156ms Info: Serializing response (Message #0 targetURI=/2/onResult, responseURI=null) (Array #0) [0] = (Typed Object #1 'net.crownmedia.flex.user.vo.UserVO') password = secret timeZone = (Typed Object #2 'net.crownmedia.flex.common.vo.TimeZoneVO') timeZoneCode = MST timeZoneDescription = Mountain Standard Time dateUpdated = Thu Mar 31 07:43:20 MST 2005 gmtOffset = -2.52E7 _remoteClass = net.crownmedia.flex.common.vo.TimeZoneVO updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 userName = cmi dateUpdated = null _remoteClass = net.crownmedia.flex.user.vo.UserVO person = (Typed Object #3 'net.crownmedia.flex.user.vo.PersonVO') jobTitle = null occupation = null dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.user.vo.PersonVO updatedByUserProfileId = null createdByUserProfileId = null middleName = Media dateCreated = Thu Mar 31 07:43:20 MST 2005 firstName = Crown nickName = CMI lastName = International titlePrefix = null updatedByUserProfileId = null securityKeys = (Array #4) [0] = (Typed Object #5 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = Insert folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.insert updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [1] = (Typed Object #6 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = View folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.view updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [2] = (Typed Object #7 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = Update folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.update updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [3] = (Typed Object #8 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = Delete folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.delete updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [4] = (Typed Object #9 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = View user dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = User.view updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 createdByUserProfileId = null status = APPROVED dateCreated = null application = (Typed Object #10 'net.crownmedia.flex.common.vo.Applicati onVO') applicationName = CMI dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.common.vo.ApplicationVO updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 -Original Message- From: Peter Farland [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 3:38 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects Just curious, what does: mx.core.Application.alert (Test with userVo + event.result[0].userName); do? Yahoo! Groups Links 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/
RE: [flexcoders] Remote object that returns an array of objects
Perhaps there's something going wrong when casting to Array (or UserVO, though that doesn't effect the second test)? However, I've not heard of this issue before... has anyone else? -Original Message- From: Jeff Krueger [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 5:56 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects Hm, that worked! Here is the log, not sure if it shows anything. Any idea how I can get that to an object? Jeff Info: Completed 'net.crownmedia.flex.user.FlexUserDelegate.getAll' with reply me thod 'onResult' in 156ms Info: Serializing response (Message #0 targetURI=/2/onResult, responseURI=null) (Array #0) [0] = (Typed Object #1 'net.crownmedia.flex.user.vo.UserVO') password = secret timeZone = (Typed Object #2 'net.crownmedia.flex.common.vo.TimeZoneVO') timeZoneCode = MST timeZoneDescription = Mountain Standard Time dateUpdated = Thu Mar 31 07:43:20 MST 2005 gmtOffset = -2.52E7 _remoteClass = net.crownmedia.flex.common.vo.TimeZoneVO updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 userName = cmi dateUpdated = null _remoteClass = net.crownmedia.flex.user.vo.UserVO person = (Typed Object #3 'net.crownmedia.flex.user.vo.PersonVO') jobTitle = null occupation = null dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.user.vo.PersonVO updatedByUserProfileId = null createdByUserProfileId = null middleName = Media dateCreated = Thu Mar 31 07:43:20 MST 2005 firstName = Crown nickName = CMI lastName = International titlePrefix = null updatedByUserProfileId = null securityKeys = (Array #4) [0] = (Typed Object #5 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = Insert folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.insert updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [1] = (Typed Object #6 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = View folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.view updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [2] = (Typed Object #7 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = Update folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.update updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [3] = (Typed Object #8 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = Delete folder dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = Folder.delete updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 [4] = (Typed Object #9 'net.crownmedia.flex.security.vo.SecurityKeyVO' ) keyDescription = View user dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.security.vo.SecurityKeyVO keyName = User.view updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 createdByUserProfileId = null status = APPROVED dateCreated = null application = (Typed Object #10 'net.crownmedia.flex.common.vo.Applicati onVO') applicationName = CMI dateUpdated = Thu Mar 31 07:43:20 MST 2005 _remoteClass = net.crownmedia.flex.common.vo.ApplicationVO updatedByUserProfileId = null createdByUserProfileId = null dateCreated = Thu Mar 31 07:43:20 MST 2005 -Original Message- From: Peter Farland [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 3:38 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] Remote object that returns an array of objects Just curious, what does: mx.core.Application.alert (Test with userVo + event.result[0].userName); do? Yahoo! Groups Links Yahoo! Groups Links Yahoo! Groups Links * To
RE: [flexcoders] Re: Problem with showBusyCursor on a popupWindow
Well it looks like something is trying to call substr on your RemoteObject and Im not sure why because I dont think any of our code should be doing it on random components. Do you have calls to substr in your code? Do you have any event handlers calling your RemoteObject that may be executing an extra time? Maybe someone set a reference to the RemoteObject elsewhere in your application? Matt From: joao_m_fernandes [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 3:29 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: Problem with showBusyCursor on a popupWindow Matt, With FB debugger I can catch this each time I try to close the titleWindow. The problem is that the method in question does not exist in my component. Remote Object Method: cfcs.core.tab_suport.substr Parameter 1: name : param1 type : number value : 0 Parameter 2: name : param2 type : number value : 2 Message Target : cfcs.core.tab_suport.substr data[array] : length[Number] : 2 [0][Number] : 0 [1][Number] : 2 Regards, João Fernandes In flexcoders@yahoogroups.com, Matt Chotin [EMAIL PROTECTED] wrote: Do you know what method it's trying to call? I suppose the window could be introspecting the contained objects but that would be weird. A workaround would maybe be to move the RemoteObject outside the TitleWindow into another class and simply have your functions call the outside remote object. Matt _ From: joao_m_fernandes [mailto:[EMAIL PROTECTED] Sent: Monday, April 04, 2005 6:27 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Problem with showBusyCursor on a popupWindow Hi there, I'm calling a RemoteObject method inside a popup with showbusycursor enabled. The problem is when I call click function to delete the popup, the busy cursor shows up calling some remote meth od that I don't use anywhere (got that from FB network debugger). If I remove showbusycursor property it works just fine. Is this an known issue? ?xml version=1.0 encoding=utf-8? mx:TitleWindow xmlns:mx=http://www.macromedia.com/2003/mxml http://www.macromedia.com/2003/mxml title=Adicionar Contacto xmlns=* initialize=initApli() click=this.deletePopUp() mx:RemoteObject id=tab_ro endpoint=/cfusion/flashservices/gateway source=cfcs.core.tab_suport showBusyCursor=true mx:method name=GetPais result=setDefaultPais()/ mx:method name=GetHabilitacao/ /mx:RemoteObject ... João Fernandes _ 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: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] * Your use of Yahoo! Groups is subject to the Yahoo! http://docs.yahoo.com/info/terms/ Terms of Service. 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.
[flexcoders] Development Environment Setup Q's
I've been thinking recently on how to setup a good development environment for multiple developers on the same Flex application. Using CVS or Subversion would be the goal. Getting a production or test version out of CVS could be done with Ant, that seems simple enough. Where I run into problems is the structure of the different files on the server side and how to get those into the module/modules in CVS properly. In all my previous projects with CVS it's been a single language involved, so having all the Java files in one module (or a few if there were shared libraries) was easy. In this case there's the actual app directory with mxml and as files. Then there's the directory with the remote java objects files (which is shared between apps). And the directory with shared as files (also shared between apps). And in my case there's also going to be the internal web services in cfc files. Making seperate modules for each of these doesn't feel right. And configuring the server side so each developer has their own directory so they can rip apart what they're working on safely doesn't seem right either. But I don't think I can install a local copy of Flex and ColdFusion on each machine to develop from (can I?). Any wisdom from the experienced here? Jason 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/
RE: [flexcoders] Re: Simple Cairngorm architecture question
Hi Josh, Here is a example of how you would do it. var alertListener:Function = Delegate.create(this,OnAlert_Click); Alert.show("This is a test of errors", "Error", Alert.OK | Alert.CANCEL, this, alertListener); function OnAlert_Click(){trace("CLICK");} or you could also do this. Alert.show("This is a test of errors", "Error", Alert.OK | Alert.CANCEL, this, Delegate.create(this,OnAlert_Click)); hope it helps. Omar Ramos Itacon Corporation Technology Manager From: Aral Balkan [mailto:[EMAIL PROTECTED] Sent: Tuesday, April 05, 2005 5:29 PMTo: flexcoders@yahoogroups.comSubject: Re: [flexcoders] Re: Simple Cairngorm architecture question Hi Josh, If you looks at the mx.controls.Alert class, you can only give theshow() method a listener object, and that object must implement aclick() method.As Omar was saying earlier, you can use a Delegate in place of the listener. Instead of a listener reference (object or function), pass it a delegate function using the Delegate factory. ie,Delegate.create ( this, someOnClickMethod ).All the best,Aral 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.
[flexcoders] datagrid with a single-node dataprovider
1) I have searched the flexcoders group for an answer 2) I don't find this documented anywhere, but every example of a datagrid has 2 or more nodes of data I have a datagrid with a dynamic datasource that contains from 0 to N elements (they are XML nodes) It works fine as long as there is more than one node. If there is one node I can't access the values in that node. I tested it with a static XML file with the same results. Here is the test: mx:Model id=testModel source=xml/test.xml / mx:DataGrid id=moduleDatagrid dataProvider={testModel.message} / Here is the XML that works: ?xml version=1.0 encoding=utf-8? messages message viewdatetest date/viewdate /message message viewdatetest date 2/viewdate /message /messages but if I modify the XML as follows, I cannot access the data in the message node: ?xml version=1.0 encoding=utf-8? messages message viewdatetest date/viewdate /message /messages I am looking for an elegant way to display data in the datagrid and wonder if anyone else has come across this 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/
Re: [flexcoders] datagrid with a single-node dataprovider
Try wrapping it with mx.utils.ArrayUtil.toArray() A single node in XML isnt neccessarily interpretted as an array, while multiple nodes of the same name are. However, you can use the static toArray method to treat the node as a 1 element array: mx:DataGrid id=moduleDatagrid dataProvider={mx.utils.ArrayUtil.toArray(testModel.message)} / At 07:37 PM 4/5/2005, you wrote: 1) I have searched the flexcoders group for an answer 2) I don't find this documented anywhere, but every example of a datagrid has 2 or more nodes of data I have a datagrid with a dynamic datasource that contains from 0 to N elements (they are XML nodes) It works fine as long as there is more than one node. If there is one node I can't access the values in that node. I tested it with a static XML file with the same results. Here is the test: mx:Model id=testModel source=xml/test.xml / mx:DataGrid id=moduleDatagrid dataProvider={testModel.message} / Here is the XML that works: ?xml version=1.0 encoding=utf-8? messages message viewdatetest date/viewdate /message message viewdatetest date 2/viewdate /message /messages but if I modify the XML as follows, I cannot access the data in the message node: ?xml version=1.0 encoding=utf-8? messages message viewdatetest date/viewdate /message /messages I am looking for an elegant way to display data in the datagrid and wonder if anyone else has come across this -- 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. 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/
Re: [flexcoders] How to get access to HttpSession in a stateful-c lass
Steven, Thanks for the reply. I realise my question wasn't quite clear - I wanted to access objects in the request object on the client. Or more specifically, pass a complex object that is available to the JSP into the Flex app. This page was what I was after... http://livedocs.macromedia.com/flex/15/flex_docs_en/wwhelp/wwhimpl/common/html/wwhelp.htm?href=2253.htm But it seems that I am limited to passing simple strings. So to use complex data for the flex app to initialize I need to call a remote service (RemoteObject, HTTP, Webservice), yes? Dan Steven Webster wrote: Dan, This may be a stupid question, but if your flex app is wrapped in in a jsp file (using something like mm:mxml source=.../) can you access variables in request scope? Or can you pass selected variables into a flex app? There's also a section in the docs Passing Request Data to Flex Applications: http://livedocs.macromedia.com/flex/15/flex_docs_en/wwhelp/wwhimpl/js/html/w whelp.htm?href=2247.htm basically, you just declare a public var on your application for anything you intend passing in as a request param, and then these request params are assigned to your public vars. Hope that helps, Steven -- Steven Webster Technical Director iteration::two This e-mail and any associated attachments transmitted with it may contain confidential information and must not be copied, or disclosed, or used by anyone other than the intended recipient(s). If you are not the intended recipient(s) please destroy this e-mail, and any copies of it, immediately. Please also note that while software systems have been used to try to ensure that this e-mail has been swept for viruses, iteration::two do not accept responsibility for any damage or loss caused in respect of any viruses transmitted by the e-mail. Please ensure your own checks are carried out before any attachments are opened. 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/
[flexcoders] ActionScript Components
Might someone point me in the direction of some good docs/examples of creating components using ActionScript. I have the RIA book and chapter 10 has some information, but its disappointingly sparse. Mostly I am interested in how to create a composite component. A component containing many other components. The examples I have seen so far simply extend a given component and alter its behavior.Right now I am creating all of my components in MXML with a separate file for their ActionScript. It's starting to get a bit messy for complex components. Any kind of a boot in the right direction would be helpful. Thanks! -- Matthew 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] datagrid with a single-node dataprovider
Jeff, That worked like a charm and saved me from some ugly code. Thanks! On Apr 5, 2005 6:02 PM, Jeff Tapper [EMAIL PROTECTED] wrote: Try wrapping it with mx.utils.ArrayUtil.toArray() A single node in XML isnt neccessarily interpretted as an array, while multiple nodes of the same name are. However, you can use the static toArray method to treat the node as a 1 element array: mx:DataGrid id=moduleDatagrid dataProvider={mx.utils.ArrayUtil.toArray(testModel.message)} / At 07:37 PM 4/5/2005, you wrote: 1) I have searched the flexcoders group for an answer 2) I don't find this documented anywhere, but every example of a datagrid has 2 or more nodes of data I have a datagrid with a dynamic datasource that contains from 0 to N elements (they are XML nodes) It works fine as long as there is more than one node. If there is one node I can't access the values in that node. I tested it with a static XML file with the same results. Here is the test: mx:Model id=testModel source=xml/test.xml / mx:DataGrid id=moduleDatagrid dataProvider={testModel.message} / Here is the XML that works: ?xml version=1.0 encoding=utf-8? messages message viewdatetest date/viewdate /message message viewdatetest date 2/viewdate /message /messages but if I modify the XML as follows, I cannot access the data in the message node: ?xml version=1.0 encoding=utf-8? messages message viewdatetest date/viewdate /message /messages I am looking for an elegant way to display data in the datagrid and wonder if anyone else has come across this -- 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. Yahoo! Groups Links 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/
[flexcoders] Re: Development Environment Setup Q's
Hi Jason, This interests me too. I'm also interested to know what development tools (IDEs) people are using for their Java, AS and Flex code. I'm currently using Eclipse and Flex Builder. I haven't played with the site definition aspect of Flex Builder yet, but it would be nice to have a single ant target to compile my java classes and publish .mxml, .as, .class and config files to my app server (Tomcat) from within Eclipse. What do people think is the most productive tool setup? Best Eclipse plugins to use? Example ant scipts? cheers Dan --- In flexcoders@yahoogroups.com, temporal_illusion [EMAIL PROTECTED] wrote: I've been thinking recently on how to setup a good development environment for multiple developers on the same Flex application. Using CVS or Subversion would be the goal. Getting a production or test version out of CVS could be done with Ant, that seems simple enough. Where I run into problems is the structure of the different files on the server side and how to get those into the module/modules in CVS properly. In all my previous projects with CVS it's been a single language involved, so having all the Java files in one module (or a few if there were shared libraries) was easy. In this case there's the actual app directory with mxml and as files. Then there's the directory with the remote java objects files (which is shared between apps). And the directory with shared as files (also shared between apps). And in my case there's also going to be the internal web services in cfc files. Making seperate modules for each of these doesn't feel right. And configuring the server side so each developer has their own directory so they can rip apart what they're working on safely doesn't seem right either. But I don't think I can install a local copy of Flex and ColdFusion on each machine to develop from (can I?). Any wisdom from the experienced here? Jason 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/
[flexcoders] Re: Simple Cairngorm architecture question
Omar, That really does help, I appreciate it. I was trying to figure out how to accomplish this... Again, thanks! -Josh --- In flexcoders@yahoogroups.com, Omar Ramos [EMAIL PROTECTED] wrote: Hi Josh, Here is a example of how you would do it. var alertListener:Function = Delegate.create(this,OnAlert_Click); Alert.show(This is a test of errors, Error, Alert.OK | Alert.CANCEL, this, alertListener); function OnAlert_Click() { trace(CLICK); } or you could also do this. Alert.show(This is a test of errors, Error, Alert.OK | Alert.CANCEL, this, Delegate.create(this,OnAlert_Click)); hope it helps. Omar Ramos Itacon Corporation Technology Manager 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/
Re: [flexcoders] Development Environment Setup Q's
We use Subversion at work. I'd rather use Visual Source Safe because the lack of checkout ticks me off. Our folder structure is conf, for config files, typically XML for Java stuff, like Hibernate, various servletSettings that are project specific, etc. The lib folder houses all of those shared libraries that the Java guys need, like the jakarta, hibernate, and OpenAMF jars. The src folder has all the project specific java, typically model, controller, and value objects. I don't know where the homeskillet keeps his Delegates, but I'm not allowed to install Eclipse to find out (wife's learning Java, fragile confidence... don't ask). Finally, we have the flash folder. The only thing the Java guys ask is my model classpath match up with their's. Since You have to map the classes server-side via OpenAMF using XML, it makes it cake, because the Java guys, with just one small meeting with us (or rather my manager, I suckered him into doing all the model stuff... he reads this list, therefore I'll balance that with his experience working with the backend systems already, and his readily available ability to faciliate communication with the backend guys. *ahem*). The Flash get's a little more complex, but I've actually set it up just in case we ever port to Flex (prays). The classes themsevles are already com.companyname.model/view/controller/valueobj. Transitioning to Flex would merely require removing the class definitions from the as files, removing the createChildren functions (for the View's), and linking the AS files to the MXML. Not a bad conversion when your porting an entire app. So, class package path stays the same. The big difference would be my main controller would be replaced by Flex's application class since Flex allows you to have a top level application. The only thing I'd then actually remove from the current folder structure in the Flash directory (classes/fla/includes/jsfl/layoutxml) would be the includes; since it's merely there for a simple top level class instantiator; Flex does this for you. Yes, we have code we like to re-use, but because each project has enough modifications, base on functionality and design, anything truly proflicly OOP-i-fied is thrown in Utilities, a top level static class. Yeah, we'll re-use GUI widgets on other projects, maybe even some data service base classes (wrappers for Remoting)... doing so wouldn't be hard, but we'd ensure each project has it's own slot in source safe, even if they were the exact same. With front-end work, you never know what class you may want to tweak. What I don't know about, however, is actual deployment. Currently, Flash is in there, and we'll make a deploy folder later for actual client-side deployment files which will be downloaded from a website and pretty much fulltime on the client-machine. The Java, however, will have it's own unique server deployment (however our back-end G feels the need to do so). Flex would be different because we'd expect SVN to allow us to see our deployed files. My guess is, Dan (our Java head) would set up an external test server for the client team (since I work from home most the time, and another developer is currently in Canada or Ecuador(sp?) and he's made the biggest firewall known to man. Even with SCP access, as a GUI guy, I'd rather just have FlexBuilder (or Eclipse) allow me to upload in-app to the test server, test my code, and then checkin locally my working source to SVN, which is actually on the in-house, behind the Firewall box via SSH (I use Tortoise since Cygwin's confusing and rtfm in a console makes me want to play Atari). This setup with Flash Java currently works great for 4 main developers and 2 designers, all of which are located in various locations at different times throughout the world. The server guy tells us how to structure our model, my manager maintains most of the front end Model part, I've passed off most hardcore visual View work to my partner front-end develooper, and we all share the bitch work of coding the Controller section. Currently, the ONLY collisions we EVER have in a team environment is the bloody, binary FLA. Naturally, Flex doesn't have this problem; we just replace it with a swf and images folder, and we're good to go. We share the directory, and we all divy up the responsibility of which parts to code; so far, MVC is working out ok. We constantly keep in commuincation over instant messenger, quick in-office meetings, phone, etc. Fortunately (or unfortunately), Subversion kind of forces you to do that. - Original Message - From: temporal_illusion [EMAIL PROTECTED] To: flexcoders@yahoogroups.com Sent: Tuesday, April 05, 2005 6:15 PM Subject: [flexcoders] Development Environment Setup Q's I've been thinking recently on how to setup a good development environment for multiple developers on the same Flex application. Using CVS or Subversion would be the
[flexcoders] createChild dynamically via DB arguments..
Can I quickly confirm something? In order to use createChild(classPath) that initial classPath has to be included before runtime correct? in that you cannot instantiate a custom MXML component unless you either xmlns: / import it? In saying that, if you have a situation where you want to via an onClick instantiate a MXML component thats path came from a DB, its not dooable as the FLEX server will need to know about this class upfront...that or you have to use attachMovie(your.mxmlFile.mxml.swf) ? -- Regards, Scott Barnes http://www.mossyblog.com http://www.flexcoder.com (Coming Soon) 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/