Hey Brad, I've been working with Flash longer than most, so I'll try and answer your questions.
" It seems every decent language should have a way to copy by reference AND by value (without a slice(0) hack), but I haven't figured it out yet with Actionscript." --Nope. You can use an loop or a couple different hacks. " myGrid.dataProvider = results; After I do that, slice(0) magically stops returning anything, and if I get rid of the slice, I get a pointer to the data, not a copy of it." --The statement above is using the remoting bindings and 'results' refers to an object, not an array. "If the columns in a data grid object could be made draggable (in order to let the users drag them around and order them easily)." --Short answer... no. Long answer... by subclassing the datagrids classes and than extending the columns class, you could do it. Of course you'd need a pretty deep knowledge of the AS2 framework and UIObject though... Cheers, Kevin -----Original Message----- From: Brad Wood [mailto:[EMAIL PROTECTED] Sent: January 10, 2006 9:32 AM To: CF-Talk Subject: RE: action script copy by value Kevin, I haven't cleared my cache recently, but I did find out why it wasn't working. If I just have a cfgrid populated by a query, I can do myGrid.dataProvider.slice(0) and get a copy of all the items in the list. I found out the PROBLEM is when I change the data provider with flash remoting: myGrid.dataProvider = results; After I do that, slice(0) magically stops returning anything, and if I get rid of the slice, I get a pointer to the data, not a copy of it. My work around for now is simply to loop over the dataProvider list and build a new array one item at a time like this: var backupDP = []; for(var i:Number = 0; i < grd_reconcile.dataProvider.length; i++) { backupDP.push(grd_reconcile.dataProvider.getItemAt(i)); } Probably not the most efficient, but it works for now. It seems every decent language should have a way to copy by reference AND by value (without a slice(0) hack), but I haven't figured it out yet with Actionscript. On a funny note-- I posted a question to the flex livedocs the other day asking if the columns in a data grid object could be made draggable (in order to let the users drag them around and order them easily) I got a reply back from an employee of Macromedia telling me that he didn't know the answer to my question. Now tell me, if the company who WROTE the software can't answer questions about it, who can?? He referred me to the macromedia forumns. Nice try-- I asked that exact question in the forums a couple weeks ago and never got a SINGLE reply. *sigh* ~Brad -----Original Message----- From: Kevin Aebig [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 10, 2006 9:05 AM To: CF-Talk Subject: RE: action script copy by value Hey Brad, This may seem a little ridiculous, but have you cleared your cache lately? It is still Flash after all... Cheers, Kevin ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:229046 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

