Subform...delete and add records

J

jimday1982

I apologize for posting so many questions on here, but the search
feature isn't being a huge help. Anyway, I have a subform where I am
trying to export the data into a table called exported_data and
naturally it has the same fields as the subform. After the data is
exported, I need to delete all records in the subform. I am lost on the
exporting to a table deal, and I have the following code for deleting
the records in the subform...the only problem is that it only deletes
the LAST record, and not all of them:

'Code for exporting records would go here
'Delete the data from the temporary table
Dim frm As Form
Set frm = Me.temp.Form
With frm.RecordsetClone
..Delete
End With

If someone could just point me in the direction, I would greatly
appreciate it. Thanks in advance.
 

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

Top