Insert Row Into Access Table With VBScript
Hi.
The following code is in an ASP page.
I'm getting an "Expected Statement" error on the line "!PPOName = sPPOName" in the code that's trying to insert a row into a 2 column MS Access table (1st column is AutoNumber):
Set oRS = Server.CreateObject("ADODB.Recordset")
Set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open sConnAccess
sSQL = "Select * from PPOs Where 1 = 0" 'Just need table structure
oRS.Open sSQL,oConn,adOpenKeyset,adLockOptimistic
With oRS
.AddNew
!PPOName = sPPOName
.Update
End With
oRS.Close
Set oRS = Nothing
oConn.Close
Set oConn = Nothing
Any suggestions?
TIA.
Rita
|