look into ObjectUtil.copy(). Note if you are using typed objects in that Array, you should be, you will need to make use of registerAlias() so this copy will work.
registerAlias(com.foo.goo, 'goo'); dest = ObjectUtil.copy( origin ); though my syntax may be a wee off... DK On Thu, Jun 12, 2008 at 6:50 PM, Chilcoat, Dee <[EMAIL PROTECTED]> wrote: > I need an example of copying fields in an array to another array, but I > don't want the fields to be pass-by-reference. I'm trying to create a > "holding"array for input in a datagrid. This is code I have used. > > > > holdData[6] = > quickEntryGrid.dataProvider[i].timerecordTrcPayRateAmount; > > holdData[7] = > quickEntryGrid.dataProvider[i].timerecordTrcSickLeaveHours; > > holdData[8] = > quickEntryGrid.dataProvider[i].timerecordTrcVacationHours; > > holdData[9] = > quickEntryGrid.dataProvider[i].timerecordTrcRegularHours; > > holdData[10] = > quickEntryGrid.dataProvider[i].timerecordTrcStraightOvertmHours; > > holdData[11] = > quickEntryGrid.dataProvider[i].timerecordTrcPremiumOvertmHours; > > holdData[12] = > quickEntryGrid.dataProvider[i].timerecordTrcOtherHours; > > holdData[13] = > quickEntryGrid.dataProvider[i].timerecordTrcOtherHoursCode; > > holdRowData[i] = holdData; > > > > The problem is that whenever a user inputs data into the quickEntryGrid, it > is reflected in the holdRowData, which I need to contain the original values > before the user enters any data. If I can't use a holding array, do I have > other options? > > > > Dee A. Chilcoat > > Enterprise Web Application Development > > University of California San Diego > > [EMAIL PROTECTED] > > (858) 534-0719 > > -- Douglas Knudsen http://www.cubicleman.com this is my signature, like it?

