could't show value at binding mode

Jan 29, 2009 at 10:00 PM
Edited Jan 29, 2009 at 10:09 PM

i 'm sorry for my poor english.
i need u help.

i use datatable or dataview source,and i add two binding column.
when i editing column B and changed value to 2,column A0 could't updated(but Source updated).

if i double click column A0, it's show true value 2.
Or
i draging horizontal scrollbar until could't watch A & B ,at this time A0 will updated.

can u help me?

thanks.

yiding

'-----DataGrid
                     _________
column          | A   |  B     |
                     _________
row(0)          | 1   |  1<-2  |

-------------------------------------------------------------CODE-------------------------------------
Dim _binding As New Binding
_binding.Path = New PropertyPath("quantity")
_binding.Mode = BindingMode.TwoWay
_binding.UpdateSourceTrigger=PropertyChanged
Dim _col As New H1DataGridTextColumn
_col.Binding = _binding
_col.Header="A"
dg.Columns.Insert(_colindex, _col)                                       

Dim _binding2 As New Binding
_binding2.Path = New PropertyPath("quantity")
_binding2.Mode = BindingMode.TwoWay
_binding2.UpdateSourceTrigger=PropertyChanged
Dim _col2 As New H1DataGridTextColumn
_col2.Binding = _binding2
_col2.Header="B"
dg.Columns.Insert(_colindex, _col2)
                                      

'----show
 dg.DataContext = p_dtDetail.DefaultView
 dg.SetBinding(Microsoft.Windows.Controls.DataGrid.ItemsSourceProperty, New Windows.Data.Binding())