How to select the last inserted row of the datagrid?

sharon

New member
Joined
Jul 26, 2005
Messages
1
Programming Experience
5-10
Hi!

I have a datagrid connected to dataset.

I am inserting row with:

oRow = Me.m_DataSet1.Tables(0).NewRow()
...
Me.m_DataSet1.Tables(0).Rows.Add(oRow)

now,
I want that the datagrid will select the new row.

How do i do it?
 
That would be the trivial case of an unsorted datagrid.

What about a datagrid, that has been sorted by the user before, the new row would be inserted at an undetermined index. How can I retrieve this index?
 
Back
Top