erro 3426

G

Guest

I'm fairly new to coding. I'm getting a run time error 3426 - This action was
cancelled by an associated object. Debug highlites the addnew line. Strange
though, I'm not getting it at the system I develope at(win 2k and office xp),
when I bring it home (Win xp and office 2k) I get the error. I checked the
refereces and they are the same. I put together another system(Win2k and
office 2k) and it also fails the same way.


Private Sub txtDateReturnedtoVHO_AfterUpdate()
'Write additional Record to tblVendorRepair

Me.RecordsetClone.AddNew

Me.RecordsetClone!fldOrderDetailID = Mid(Me.txtRMANumber, 5)
Me.RecordsetClone!fldDateToVHO = txtDateReturnedtoVHO
Me.RecordsetClone!fldRMANumber = txtRMANumber
Me.RecordsetClone!fldReasonForReturn = txtReasonForReturn
Me.RecordsetClone!fldNCWarranty = -1

Me.RecordsetClone.Update

MsgBox ("Record Written To TblVendorRepair")
 
T

Tim Ferguson

I'm fairly new to coding. I'm getting a run time error 3426 - This
action was cancelled by an associated object. Debug highlites the
addnew line.
Me.RecordsetClone.AddNew

I assume this is happening behind an active form... it sounds like a very
risky thing to do, and I am not surprised that Access gives inconsistent
responses to it.

I would take the safe way out and create a proper INSERT statement to
write the record into the table, and then requery the form to get the
recordset updated clean.

Best of luck


Tim F
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Error 3426 1

Top