J
Jayyde
Dim cmd As ADODB.Command
Dim cnn As ADODB.Connection
Dim strSQL As String
Dim index As Long
Set cnn = Application.CurrentProject.Connection
Set cmd = New ADODB.Command
Set cmd.ActiveConnection = cnn
strSQL = "DELETE FROM dbo_tblProductCategoryValue " _
& "WHERE iProductMasterId=" _
& id _
& " AND iProductCategoryId=" _
& intCatID & ";"
cmd.CommandText = strSQL
cmd.Execute***********
That code is throwing a catastrophic failure on the .execute command. I put
a breakpoint in and grabbed the strSQL, put it into query manager and it's
fine. The weird thing is, it's acting like it's doing the delete twice off
this one command, becuase the record's getting deleted. I have no idea
what's causing this given that I'm using the same code in another form with
no issues. (I'm sure it's something retarded again, but any help you gurus
can give me is much appreciated =) )
Thanx ahead of time!
-Jayyde
Dim cnn As ADODB.Connection
Dim strSQL As String
Dim index As Long
Set cnn = Application.CurrentProject.Connection
Set cmd = New ADODB.Command
Set cmd.ActiveConnection = cnn
strSQL = "DELETE FROM dbo_tblProductCategoryValue " _
& "WHERE iProductMasterId=" _
& id _
& " AND iProductCategoryId=" _
& intCatID & ";"
cmd.CommandText = strSQL
cmd.Execute***********
That code is throwing a catastrophic failure on the .execute command. I put
a breakpoint in and grabbed the strSQL, put it into query manager and it's
fine. The weird thing is, it's acting like it's doing the delete twice off
this one command, becuase the record's getting deleted. I have no idea
what's causing this given that I'm using the same code in another form with
no issues. (I'm sure it's something retarded again, but any help you gurus
can give me is much appreciated =) )
Thanx ahead of time!
-Jayyde