G
Guest
On the On_Click event, I have the following code:
Private Sub Report3Button_Click()
Dim stDocName As String
If acCtrlMask = 2 Then
stDocName = "WarehouseYTDReport"
Else
stDocName = "WarehouseErrorReport"
End If
DoCmd.OpenReport stDocName, acPreview
End If
End Sub
When I run this code, I only get one response,
stDocName = "WarehouseYTDReport"
Can someone tell me what I am doing wrong?
Private Sub Report3Button_Click()
Dim stDocName As String
If acCtrlMask = 2 Then
stDocName = "WarehouseYTDReport"
Else
stDocName = "WarehouseErrorReport"
End If
DoCmd.OpenReport stDocName, acPreview
End If
End Sub
When I run this code, I only get one response,
stDocName = "WarehouseYTDReport"
Can someone tell me what I am doing wrong?