Hi All,

i have a littile problem here which is:

- i build the dataset at runtime and fill the DataGridView with the DataSet Data OK.

- then, when the user clicks on the record in the DataGridView, i take the index of the row and go to the DataSet to get some information to fill in additional fields at the top of the form.

{

txtServiceName.Text = dstServices.Tables(COMSERVICES.Table_Name).Rows(e.RowIndex).Item(COMSERVICES.SERVICE_NAME).ToString

}

- the problem is when sorting any column in the DataGridView and click on any record on it. it gives me the wrong information in the above fields. this is due to that the grid indeces are changed but the indeces of the DataSet don't change.

- so i have to do something that will allow me to know the actual index of the current grid record in the DataSet.

thanks for your help