Is this a datagrid/combo bug???

  • Thread starter Thread starter Jan Nielsen
  • Start date Start date
J

Jan Nielsen

Hi
I have a form with a combo and a datagrid

The combo has these properties:
Datasource: DataSet11.tPersoner
Displaymember: ChristianName
It does not have any databindings

The datagrid has these properties:
Dim dv As DataView = DataSet11.tPersoner.DefaultView
DataGrid1.DataSource = dv

Because I want different bindingmanagers for the two controls.

Now when I change the current cell in the datagrid (by clicking with the
mouse) they are not synchronized (which I don´t want them to be). But if I
sort the datagrid by clicking on a column header suddenly the combo shows
the ChristianName of an (appearantly random) row in the datagrid.

(I have created two different CurrencyManagers for the controls. And they
are not synchronized. their .Position are not the same)

It seems strange to me.

Any explanations?


best regards

Jan
 
try to configure dataview without defaultview. means, configure thru
tablename property. and check

hope that helps

Rajesh Patel
 
Hi Rajesh
Thanks for answering.
That solved the problem. But did not explain why the original problem
arouse.

Thanks

Jan
 
because, when you work directly work with datatable. it's actually
work with defaultview. so, indirectly, you were binding same
currencymanagers for 2 controls. now, you created exclusive dataview
with different currencymanagers and it works

Rajesh Patel
 
Back
Top