Re: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-06-23 Thread hank williams
The exact thing that Jonathan describes below in the referenced email is happening to me. I am attempting to programatically create a bindable arrayCollection and use that arrayCollection as a dataProvider for a dataGrid. When I do this, only the last item in the list is selectable with the mous

Re: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-13 Thread Ted Patrick
Always learning... :) "A type cast is NOT about changing the type at runtime." I agree but the pattern of use for casting using Class( obj ) collides directly with global functions created for type conversion. If the following methods are used to upcast an object, these can wildly change the va

RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Gordon Smith
Behalf Of Jens Halm Sent: Wednesday, April 12, 2006 2:49 PM To: Ted Patrick Subject: Re: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug... > Geoffrey, > This is a common misconception about return types. In the Flex > docs, the type specified is the lowest

RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Gordon Smith
Subject: Re: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug... Ted, it seems like you have a wrong perception of what a type cast actually is, not only in ActionScript, but in general. A type cast is NOT about changing the type at runtime. if you write something

Re: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Jens Halm
Ted, it seems like you have a wrong perception of what a type cast actually is, not only in ActionScript, but in general. A type cast is NOT about changing the type at runtime. if you write something like this: var o:Object = new ClassA(); var b:ClassB = ClassB(o); this will actually *fail* (t

RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Ted Patrick
Patrick Sr. Consultant [EMAIL PROTECTED] tel: 1.866.CYNERGY http://www.cynergysystems.com From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Jens Halm Sent: Wednesday, April 12, 2006 5:49 PM To: Ted Patrick Subject: Re: [

Re: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Jens Halm
> Geoffrey, > This is a common misconception about return types. In the Flex > docs, the type specified is the lowest subclass supported for the > returned data. If the return type is Object, this can include Array, > Boolean, String, Number, components, and most custom classes. > But alas that

RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Ted Patrick
Geoffrey, This is a common misconception about return types. In the Flex docs, the type specified is the lowest subclass supported for the returned data. If the return type is Object, this can include Array, Boolean, String, Number, components, and most custom classes. But alas that is not th

RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Geoffrey Williams
Sent: Wednesday, April 12, 2006 2:48 PM To: flexcoders@yahoogroups.com Subject: RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug... JB, Why are you casting dg.selectedItem when it is already is a ResourceVO? The selectedItem value is the item passed int

RE: [flexcoders] programatically assigning an ArrayCollection as the DataProvider bug...

2006-04-12 Thread Ted Patrick
JB, Why are you casting dg.selectedItem when it is already is a ResourceVO? The selectedItem value is the item passed into the addItem method. ArrayCollection has events to support updating a view (DataGrid, List, ComboBox). This can be accessed through the component itself or via the dataProv