I have two reports. One uses a baseline set of dates, the other uses adjusted dates. Both utilize a query that is filtered from a QBF. I use a button on a form for each report that is generated by a macro to include the query as a filter and display the report in PrintPreview. I've treid umteen different "If...Then...Else (ElseIf)" and "IIf" statements. I'm close, but no cigar.
I'd like an option button (or checkbox) that gives the different date options when you click a single button to get the report. Here's where I'm at:
Private Sub Command264_Click()
'If Option Button is checked, run Report with Scheduled Green Tag Dates
If (Me!SGTOption = True) Then DoCmd.RunMacro "Mcr: OpenEquipmentList_S-OAT_NotElect_D1D"
If (Me!SGTOption = False) Then DoCmd.RunMacro "Mcr: OpenEquipmentList_A-OAT_NotElect_D1D"
End Sub
I'd like an option button (or checkbox) that gives the different date options when you click a single button to get the report. Here's where I'm at:
Private Sub Command264_Click()
'If Option Button is checked, run Report with Scheduled Green Tag Dates
If (Me!SGTOption = True) Then DoCmd.RunMacro "Mcr: OpenEquipmentList_S-OAT_NotElect_D1D"
If (Me!SGTOption = False) Then DoCmd.RunMacro "Mcr: OpenEquipmentList_A-OAT_NotElect_D1D"
End Sub