hello guys, i'm having a very strange problem, this is a
simple insert code. andthe insert stmt has NO problem cos
i've tried it on my access table.
and heres the error msg
Operation must use an updateable query.
Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and where
it originated in the code.
Exception Details: System.Data.Ole Db.OleDbExcepti on:
Operation must use an updateable query.
Source Error:
Line 31: objCommand = New OleDbCommand("I NSERT
INTO DailyUpdates(co ntent) VALUES('HELLO') ", objConn)
Line 32: objCommand.Conn ection.Open()
Line 33: objCommand.Exec uteReader()
Line 34: objCommand.Conn ection.Close()
Line 35: End Sub
BELOW HERE IS THE CODE WHICH I USE...
Private Sub btnInsert_Click (ByVal sender As
System.Object, ByVal e As System.EventArg s) Handles
btnInsert.Click
Dim objConn As New OleDbConnection
("PROVIDER=Micr osoft.Jet.OLEDB .4.0; Data
source=C:\Proje cts\SomeProject \Data\dailydose db.mdb")
Dim objCommand As OleDbCommand
objCommand = New OleDbCommand("I NSERT INTO
DailyUpdates(co ntent) VALUES('HELLO') ", objConn)
objCommand.Conn ection.Open()
objCommand.Exec uteReader()
objCommand.Conn ection.Close()
End Sub
thanks for helping me out.. once again, thanks in advance.
simple insert code. andthe insert stmt has NO problem cos
i've tried it on my access table.
and heres the error msg
Operation must use an updateable query.
Description: An unhandled exception occurred during the
execution of the current web request. Please review the
stack trace for more information about the error and where
it originated in the code.
Exception Details: System.Data.Ole Db.OleDbExcepti on:
Operation must use an updateable query.
Source Error:
Line 31: objCommand = New OleDbCommand("I NSERT
INTO DailyUpdates(co ntent) VALUES('HELLO') ", objConn)
Line 32: objCommand.Conn ection.Open()
Line 33: objCommand.Exec uteReader()
Line 34: objCommand.Conn ection.Close()
Line 35: End Sub
BELOW HERE IS THE CODE WHICH I USE...
Private Sub btnInsert_Click (ByVal sender As
System.Object, ByVal e As System.EventArg s) Handles
btnInsert.Click
Dim objConn As New OleDbConnection
("PROVIDER=Micr osoft.Jet.OLEDB .4.0; Data
source=C:\Proje cts\SomeProject \Data\dailydose db.mdb")
Dim objCommand As OleDbCommand
objCommand = New OleDbCommand("I NSERT INTO
DailyUpdates(co ntent) VALUES('HELLO') ", objConn)
objCommand.Conn ection.Open()
objCommand.Exec uteReader()
objCommand.Conn ection.Close()
End Sub
thanks for helping me out.. once again, thanks in advance.
Comment