Click to See Complete Forum and Search --> : Ugh...run-time error when deleting a record
simpleton
Jul 12th, 2000, 01:33 PM
When using adoHeader.Recordset.Delete to delete a record, I am getting the following error message: "-2147217887 run-time error" "A given HRow referred to a hard- or soft- deleted row". Any ideas why I am getting this error and how to get rid of it? I only get this on the delete function - the add and update functions work fine.
Thanks in advance -
are you opening the recordset as dynamic?
Or
try to delete records through the connection object?
strSQL = "DELETE FROM tabelname WHERE somefield = '" & "delete me" & "'"
Connection.Execute(strSQL)
then you dont have to deal with the recordset
simpleton
Jul 12th, 2000, 01:50 PM
Thanks, I could give that a try. I was attempting to delete the current record in an ADO recordset just by using the .Delete function...
I'll try it using the SQL statement and see if it gets me around the problem :-)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.