3 datagridviews - How do I update?

ppirates

Member
Joined
Jul 19, 2006
Messages
12
Programming Experience
10+
I am having problems updating 3 datagridviews that I have on the one screen, or any one of them individually.

I am using VB 2005 and an Access database.

The screen shows 3 lists of price rates in datagridviews, these are split into 3 to show 3 categories, and so that they can all be seen on the one screen.

I can get the data to populate ok, using the code below, but I can't get the database to update.

Dim VehLabDT AsNew DataTable()
VehLabDT = Me.RateCardTableAdapter.GetRateCardByCustIDandType(clsGlobal.CustID, "V")

' Set data source for HistoryBindingSource
RateCardBindingSource.DataSource = VehLabDT

' Set the data source for dgvVehLab to RateCardBindingSource.
dgvVehLab.DataSource = RateCardBindingSource

The other examples of the 3 sets of population of the datagridviews is very similar to the above.

I was trying to use the following code to do the update....

Me.RateCardTableAdapter.Update(VehLabDT)

Can anyone help me with this please?

Thanks
Colin
 
Back
Top