Thursday, May 17, 2007

Adding rows to another table

When you add a row from a datatable to another with

table(0).rows.add(theRow)

you will get the error
This row already belongs to another table

Instead of the table.add(theRow) command, you can use the table.importrow(therow) command

This will preserve the rowstate, so if the row was unchanged in the first datatable,
it will be unchanged in the new table.

this can be usefull for ecample after a select on a datatable

No comments: