Link to home
Start Free TrialLog in
Avatar of rwallacej
rwallacej

asked on

DataSet, BindingNavigator and DataGridView

Hi
I've have a Dataset displayed on a Datagridview.
I want a navigator for the datagridview. Using the following, the navigator is bound to DataSet (1...x records are on navigator), and data is displayed on DataGridView.

However I can't get navigator to changed selected item on datagridview.

        Dim binding As New BindingSource
        binding.DataSource = dt

        Me.BindingNavigator1.BindingSource = binding
        DataGridView1.DataSource = binding   'tried ds and dt here too

Help please, thank-you.
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

The relationship between the DataGridView and the BindingSource in this case is from the DataGridView to the BindingSource, and not the other way round.

Bob
Avatar of rwallacej
rwallacej

ASKER

Bob,
Can you elaborate a little please on what the revised code should be?

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
thanks Bob again for all your help.

works great

Richard