i am clicking a button on a form in access:
Private Sub Command29_Click()
some_variable = 2
stDocName = "test"
DoCmd.OpenQuery stDocName
End Sub
my query looks like this:
SELECT *
FROM [some_table]
WHERE [Occurrence Number]=some_variable;
is this possible to do?