I have two queries that I want to output to two different text boxes. Query 8 should run first, since Query 9 is dependent on Query 8 results. I am trying to do this by a button click, but right now I am stuck with how to modify this code. Any help would be appreciated.
Code:
Private Sub Command41_Click()
On Error GoTo Err_Command41_Click
Dim stDocName As String
stDocName = "Query8_inv"
DoCmd.OpenQuery stDocName, acNormal, acEdit
stDocName2 = "Query9_inv"
DoCmd.OpenQuery stDocName2, acNormal, acEdit
Exit_Command41_Click:
Exit Sub
Err_Command41_Click:
MsgBox Err.Description
Resume Exit_Command41_Click
End Sub