This project is read-only.

DataGridView SetBinding

Sep 5, 2008 at 7:25 AM
I'm trying to use the datagridview control in a eWPF browser application.

I used the below code to fetch data and assign to datagridview.

            OPaLDB = New DB2Connection("DB2DatabaseConnectionString")
            OPaLDB.Open()
            Dim daDB2 As New DB2DataAdapter("select * from Table", OPaLDB)
            Dim dtDB2 As New DataTable
            daDB2.Fill(dtDB2)
            Dim dvDB2 As DataView = dtDB2.DefaultView

            'dgvEOD.ItemsSource = dtDB2
            Dim bDgv As New Binding
            bDgv.Mode = BindingMode.OneWay
            bDgv.Source = dvDB2
            dgvEOD.SetBinding(AC.AvalonControlsLibrary.Controls.DataGridView.ItemsSourceProperty, bDgv)

On the last line i get the error - AmbiguousMatchException was unhandled.  Where am i going wrong?  Any help will be appreciated.

Thanks
RV