G
Guest
In an access database, I have a start menu with buttons on it. In the
problem that I am working on, if the user presses button A, I am trying to
make it so that a pop-up box will appear with two blank fields for a Begin
Date and an End Date. Once the user has put values into these fields, and
presses the close (or enter) button, I want those values to be used in
running a make-table query via a macro. Then, the results of the make table
query are to be displayed on a separate form which can not be edited. I have
everything working so far except for the part where the pop-up box holds the
begin and end dates. I am desperate. Please help!
Here is what I have so far:
Private Sub Command299_Click()
On Error GoTo Err_Command299_Click
Dim stDocName As String
Dim stLinkCriteria As String
DoCmd.OpenForm "frm_QOSDateRange"
DoCmd.OpenQuery "qry_MP2_QOS_ISSREC_Data_tbl", , acReadOnly
stDocName = "frm_MP2_QOS_ISSREC_Data_JP_Linked_To_Table"
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_Command299_Click:
Exit Sub
Err_Command299_Click:
MsgBox Err.DESCRIPTION
Resume Exit_Command299_Click
End Sub
problem that I am working on, if the user presses button A, I am trying to
make it so that a pop-up box will appear with two blank fields for a Begin
Date and an End Date. Once the user has put values into these fields, and
presses the close (or enter) button, I want those values to be used in
running a make-table query via a macro. Then, the results of the make table
query are to be displayed on a separate form which can not be edited. I have
everything working so far except for the part where the pop-up box holds the
begin and end dates. I am desperate. Please help!
Here is what I have so far:
Private Sub Command299_Click()
On Error GoTo Err_Command299_Click
Dim stDocName As String
Dim stLinkCriteria As String
DoCmd.OpenForm "frm_QOSDateRange"
DoCmd.OpenQuery "qry_MP2_QOS_ISSREC_Data_tbl", , acReadOnly
stDocName = "frm_MP2_QOS_ISSREC_Data_JP_Linked_To_Table"
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_Command299_Click:
Exit Sub
Err_Command299_Click:
MsgBox Err.DESCRIPTION
Resume Exit_Command299_Click
End Sub