select new row in sorted datagrid

  • Thread starter Thread starter Hugh Mungo
  • Start date Start date
H

Hugh Mungo

Hi,

I have a datagrid that is bound to a dataview.
How can I select make sure that when a new row is added it is selected -
even if the datagrid is sorted.
I am using C# in a Windows Forms application.

Thanks
 
Hi Hugh,

Hugh Mungo said:
Hi,

I have a datagrid that is bound to a dataview.
How can I select make sure that when a new row is added it is selected -
even if the datagrid is sorted.
I am using C# in a Windows Forms application.

Thanks

Get the index of the row added, and set the SelectedRowIndex property of the
DataGrid. After that call Select on the DataGrid.

Try microsoft.public.dotnet.framework.windowsforms for windows forms
specific questions.

Hope this helps,
Tom T.
 
How do I get the index of the row added?


Get the index of the row added, and set the SelectedRowIndex property of the
DataGrid. After that call Select on the DataGrid.

Try microsoft.public.dotnet.framework.windowsforms for windows forms
specific questions.

Hope this helps,
Tom T.
 
Back
Top