Append and Delete query (1 Viewer)

TimjHebert

Registered User.
Local time
Today, 15:12
Joined
Dec 12, 2004
Messages
40
I have 2 databases which are mirror images of each other. one db is named rent and the other is named renthistory. in the db i have 2 tables, tblcustomer and tblradio. i would like a button on my form to append the current record to the renthistory db and then delete the current record. how can i do this?

Thanks in advance!
Tim
 

godofhell

Database Guru
Local time
Today, 13:12
Joined
May 20, 2005
Messages
180
Create your append and delete querie, then in the VBCode write code that runs the queries when the button is clicked. Of course make sure that your query criteria is set to delete the selected record.

Sub mybutton_onClick()
Docmd.Runquery "qryAppendtohistory"
Docmd.Runquery "qryDeleteRecord"
End Sub
 

TimjHebert

Registered User.
Local time
Today, 15:12
Joined
Dec 12, 2004
Messages
40
append and delete

Thanks for the information, but how do i set my code to append the current record?

Thanks in Advance!
Tim
 

Users who are viewing this thread

Top Bottom