G
Guest
This insert does not work and i don't know why. I get the following error
System.Data.OleDb.OleDbException: Operation must use an updateable query.
on the cmdInsert.ExecuteNonQuery()
I'm sure it's going to be simple
thanks
kes
Function AddStone(ByVal thsStone)
Dim conAddStone As OleDbConnection
Dim strInsert As String
Dim cmdInsert As OleDbCommand
conAddStone = New
OleDbConnection("PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA Source=" & thsSitePath
& "db\damarstone.mdb")
strInsert = "Insert into typ (TypName) Values(@thsStone)"
cmdInsert = New OleDbCommand(strInsert, conAddStone)
'cmdInsert.Parameters.Add("@thsStone", thsStone)
conAddStone.Open()
cmdInsert.ExecuteNonQuery()
conAddStone.Close()
End Function
System.Data.OleDb.OleDbException: Operation must use an updateable query.
on the cmdInsert.ExecuteNonQuery()
I'm sure it's going to be simple
thanks
kes
Function AddStone(ByVal thsStone)
Dim conAddStone As OleDbConnection
Dim strInsert As String
Dim cmdInsert As OleDbCommand
conAddStone = New
OleDbConnection("PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA Source=" & thsSitePath
& "db\damarstone.mdb")
strInsert = "Insert into typ (TypName) Values(@thsStone)"
cmdInsert = New OleDbCommand(strInsert, conAddStone)
'cmdInsert.Parameters.Add("@thsStone", thsStone)
conAddStone.Open()
cmdInsert.ExecuteNonQuery()
conAddStone.Close()
End Function