[flexcoders] Re: List dataProvider issue

2006-04-27 Thread Suzy Lawson



Thanks Gordon. Changing the class to dynamic also fixed it per a
blog i found from your help.

http://www.simb.net/blog/index.cfm/2006/4/19/Using-Flex-2-List-Controls-with-ColdFusion-Components

--- In flexcoders@yahoogroups.com, Gordon Smith [EMAIL PROTECTED] wrote:

 Make ItemVO implement IUID.
 
 - Gordon
 
 
 -Original Message-
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Suzy Lawson
 Sent: Thursday, April 27, 2006 5:48 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] List dataProvider issue (don't wanna say bug!!)
 
 I broke this issue down to a VERY simple example and the problem is
 still there.
 When I create an ArrayCollection of items and assign it to the data
 provider of a List. The very first item in the list cannot be
 selected. Very Weird. If I change my collection of custom VO objects
 to generic {} type objects, it works fine. I've tried messing with the
 [Bindable] meta tag to no avail. Anyone come across anything like
 this?? I don't want to use generic objects as a work around.
 
 ?xml version=1.0 encoding=utf-8?
 mx:Application xmlns:mx=http://www.adobe.com/2006/mxml 
  xmlns=* layout=absolute creationComplete=sampleData();
 mx:Script
  ![CDATA[
   import mx.collections.ArrayCollection;
   import org.ItemVO;
   
   [Bindable] 
   private var items : ArrayCollection ;

  private function sampleData()
   {
var item1 : ItemVO = new ItemVO();
var item2 : ItemVO = new ItemVO();
item1.name = item1 name;
item1.type = one; 
item2.name = item2 name;
item2.type = two; 
items = new ArrayCollection([item1,item2]);
   }
   
  ]]
 /mx:Script
  mx:Panel id=test title=Item Title
   mx:List id=columnList dataProvider={items}
 labelField=name/
  /mx:Panel
 /mx:Application
 
 
 the ItemVO class..
 --
 package org {
 //I have the same effect whether [Bindable] is here or not
  public class ItemVO {
   public var name : String;
   public var type : String;
  }
 }
 
 
 
 
 
 
 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Search Archives:
 http://www.mail-archive.com/flexcoders%40yahoogroups.com 
 Yahoo! Groups Links












--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








  
  
SPONSORED LINKS
  
  
  

Web site design development
  
  
Computer software development
  
  
Software design and development
  
  


Macromedia flex
  
  
Software development best practice
  

   
  







  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  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] Re: List dataProvider issue

2006-04-27 Thread Gordon Smith



OK, but we recommend implementing IUID because non-dynamic objects are
larger and slower than dynamic ones. It could be as simple as

public class ItemVO {
 public var name : String;
 public var type : String;
 public function get uid():String { return name; }
 public function set uid(value:String):void { name = value; }
}

if the name field uniquely identifies an item.

- Gordon



-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Suzy Lawson
Sent: Thursday, April 27, 2006 6:06 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: List dataProvider issue

Thanks Gordon. Changing the class to dynamic also fixed it per a
blog i found from your help.

http://www.simb.net/blog/index.cfm/2006/4/19/Using-Flex-2-List-Controls-
with-ColdFusion-Components

--- In flexcoders@yahoogroups.com, Gordon Smith [EMAIL PROTECTED] wrote:

 Make ItemVO implement IUID.
 
 - Gordon
 
 
 -Original Message-
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On
 Behalf Of Suzy Lawson
 Sent: Thursday, April 27, 2006 5:48 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] List dataProvider issue (don't wanna say bug!!)
 
 I broke this issue down to a VERY simple example and the problem is
 still there.
 When I create an ArrayCollection of items and assign it to the data
 provider of a List. The very first item in the list cannot be
 selected. Very Weird. If I change my collection of custom VO objects
 to generic {} type objects, it works fine. I've tried messing with the
 [Bindable] meta tag to no avail. Anyone come across anything like
 this?? I don't want to use generic objects as a work around.
 
 ?xml version=1.0 encoding=utf-8?
 mx:Application xmlns:mx=http://www.adobe.com/2006/mxml 
  xmlns=* layout=absolute creationComplete=sampleData();
 mx:Script
  ![CDATA[
   import mx.collections.ArrayCollection;
   import org.ItemVO;
   
   [Bindable] 
   private var items : ArrayCollection ;

  private function sampleData()
   {
var item1 : ItemVO = new ItemVO();
var item2 : ItemVO = new ItemVO();
item1.name = item1 name;
item1.type = one; 
item2.name = item2 name;
item2.type = two; 
items = new ArrayCollection([item1,item2]);
   }
   
  ]]
 /mx:Script
  mx:Panel id=test title=Item Title
   mx:List id=columnList dataProvider={items}
 labelField=name/
  /mx:Panel
 /mx:Application
 
 
 the ItemVO class..
 --
 package org {
 //I have the same effect whether [Bindable] is here or not
  public class ItemVO {
   public var name : String;
   public var type : String;
  }
 }
 
 
 
 
 
 
 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Search Archives:
 http://www.mail-archive.com/flexcoders%40yahoogroups.com 
 Yahoo! Groups Links








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links



 








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








  
  
SPONSORED LINKS
  
  
  

Web site design development
  
  
Computer software development
  
  
Software design and development
  
  


Macromedia flex
  
  
Software development best practice
  

   
  







  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  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] Re: List dataProvider issue

2006-04-27 Thread Matt Chotin



And note the hard requirement for this will go away in beta 3 though the
best practice of implementing IUID remains.

Matt

-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Gordon Smith
Sent: Thursday, April 27, 2006 6:21 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: List dataProvider issue

OK, but we recommend implementing IUID because non-dynamic objects are
larger and slower than dynamic ones. It could be as simple as

public class ItemVO {
 public var name : String;
 public var type : String;
 public function get uid():String { return name; }
 public function set uid(value:String):void { name = value; }
}

if the name field uniquely identifies an item.

- Gordon



-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Suzy Lawson
Sent: Thursday, April 27, 2006 6:06 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: List dataProvider issue

Thanks Gordon. Changing the class to dynamic also fixed it per a
blog i found from your help.

http://www.simb.net/blog/index.cfm/2006/4/19/Using-Flex-2-List-Controls-
with-ColdFusion-Components

--- In flexcoders@yahoogroups.com, Gordon Smith [EMAIL PROTECTED] wrote:

 Make ItemVO implement IUID.
 
 - Gordon
 
 
 -Original Message-
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On
 Behalf Of Suzy Lawson
 Sent: Thursday, April 27, 2006 5:48 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] List dataProvider issue (don't wanna say bug!!)
 
 I broke this issue down to a VERY simple example and the problem is
 still there.
 When I create an ArrayCollection of items and assign it to the data
 provider of a List. The very first item in the list cannot be
 selected. Very Weird. If I change my collection of custom VO objects
 to generic {} type objects, it works fine. I've tried messing with the
 [Bindable] meta tag to no avail. Anyone come across anything like
 this?? I don't want to use generic objects as a work around.
 
 ?xml version=1.0 encoding=utf-8?
 mx:Application xmlns:mx=http://www.adobe.com/2006/mxml 
  xmlns=* layout=absolute creationComplete=sampleData();
 mx:Script
  ![CDATA[
   import mx.collections.ArrayCollection;
   import org.ItemVO;
   
   [Bindable] 
   private var items : ArrayCollection ;

  private function sampleData()
   {
var item1 : ItemVO = new ItemVO();
var item2 : ItemVO = new ItemVO();
item1.name = item1 name;
item1.type = one; 
item2.name = item2 name;
item2.type = two; 
items = new ArrayCollection([item1,item2]);
   }
   
  ]]
 /mx:Script
  mx:Panel id=test title=Item Title
   mx:List id=columnList dataProvider={items}
 labelField=name/
  /mx:Panel
 /mx:Application
 
 
 the ItemVO class..
 --
 package org {
 //I have the same effect whether [Bindable] is here or not
  public class ItemVO {
   public var name : String;
   public var type : String;
  }
 }
 
 
 
 
 
 
 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Search Archives:
 http://www.mail-archive.com/flexcoders%40yahoogroups.com 
 Yahoo! Groups Links








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links



 




--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links



 








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








  
  
SPONSORED LINKS
  
  
  

Web site design development
  
  
Computer software development
  
  
Software design and development
  
  


Macromedia flex
  
  
Software development best practice
  

   
  







  
  
  YAHOO! GROUPS LINKS



  Visit your group "flexcoders" on the web.
  To unsubscribe from this group, send an email to:[EMAIL PROTECTED]
  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.