jaz854 3 Newbie Poster

Hello, I get this error message when I try to do an update on my form. Can somebody help. Please see the my code below.

Imports System
Imports System.Data
Imports System.Data.OleDb
Imports System.Windows.Forms


Public Class Incilistfrm
Inherits System.Windows.Forms.Form
Dim conn As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Documents and Settings\Administrator\Desktop\Project\MyDatabasev1.mdb")
Dim cmd As OleDbCommand
Dim incidentDa As OleDbDataAdapter
Dim incidentDs As DataSet
Dim cb As OleDbCommandBuilder
Dim builder As OleDbCommandBuilder

Private Sub Incilistfrm_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

conn.ConnectionString = _
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Documents and Settings\Administrator\Desktop\Project\MyDatabasev1.mdb"

incidentDa = New OleDbDataAdapter

incidentDa.SelectCommand = New OleDbCommand("Select * from [Password]", conn)

'incidentDa.SelectCommand = New OleDbCommand("Select * from Incident", conn)

builder = New OleDbCommandBuilder(incidentDa)

incidentDs = New DataSet("Password")

incidentDa.Fill(incidentDs)

DataGrid1.DataSource = incidentDs.Tables(0)

End Sub

Private Sub DataGrid1_Navigate(ByVal sender As System.Object, ByVal ne As System.Windows.Forms.NavigateEventArgs)

End Sub

Private Sub buttonUpdate_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnUpdate.Click

builder.GetUpdateCommand()

Dim s As String

s = builder.GetUpdateCommand().CommandText

incidentDa.Update(incidentDs)

End Sub