In the code below case 1 and 2 are working as they should. When I make the report selection from my option group to run case 3 I get "Run-time error 3075 unknown". When I go to the code and check the values for some reason the acViewPreview = 2 when it should be option 3. The strWhere and cboSelectMFG have the correct value. What could I be doing wrong?
Private Sub cmdPreviewReport_Click()
Dim strWhere As String
Dim varWhere As Variant
Select Case Me!OptPrint
strWhere = "JN='" & Me.cboSelectJob & "'"
DoCmd.OpenReport "rptByJob", acViewPreview, WhereCondition:=strWhere
varWhere = "PurchaseOrderID=" & Me.cboSelectPONum
DoCmd.OpenReport "rptByPONum", acViewPreview, WhereCondition:=varWhere
strWhere = "MN='" & Me.cboSelectMFG & "'"
DoCmd.OpenReport "rptByMFG", acViewPreview, WhereCondition:=strWhere