Home All Groups Group Topic Archive Search About
Author
17 May 2006 12:33 AM
wandii
Hi,
   I have a datagrid attached to a datatable and upon inserting a new
record how can I move
the current postion to the inserted row.  For example, I already have 3
records in datagrid
and first row is highlighted after adding a new row, 4th one,  I would
like to move the row position to the 4th row.

I tried Datagrid.Rows.Find(newrow), select() no luck.  Please let me
know if there is an easy way to do this.

Thanks in advance

Author
17 May 2006 3:53 AM
diego
Hi wandii,

Try this:

bindingcontext(dGrid.datasource).position = dTable.rows.count-1

hth

Diego
Author
17 May 2006 4:05 PM
wandii
Thank you Diego - worked really nice!

May I ask another question.  When a user adds a new row and has not
saved it yet the existing rows state change to edit mode too.  How can
I disable existing
row state to unchanged.  Please let me know.

Thanks in advance.