Running Multiple Append Queries through a command button.

Joined
Jun 12, 2009
Messages
1
Reaction score
0
Hello All,

I have three append queries that I wish to run in succession when a user clicks a single command button on a form. So far I have been able to run my first append query through the Command Button Wizard. The current VBA coding is as follows.

"On Click"

Private Sub AppendQuerySiteComponents_Click()
On Error GoTo Err_AppendQuerySiteComponents_Click
Dim stDocName As String
stDocName = "AppendSitecomponents"
DoCmd.OpenQuery stDocName, acNormal, acEdit
Exit_AppendQuerySiteComponents_Click:
Exit Sub
Err_AppendQuerySiteComponents_Click:
MsgBox Err.Description
Resume Exit_AppendQuerySiteComponents_Click

End Sub

I would like to add a DoCmd forqueries "AppendProjectName" and " AppendSiteComponents.

My VBA coding is at a novice level. How would I insert these DoCmd operations and how would the VBA code work. Any other work around for running these three queries on a single command or On Close will be appreciated.
Thanks
-Higel
 

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