R
ryan.fitzpatrick3
Hi I have a case select code on my listbox. The listbox is called
ReportID, I have an event procedure on dbl click. But when I dbl click
the selection nothing happens. I have 2 columes of information that is
shown in the list box, column 1 has report name, column 2 has report
description. I put the report name in the case selection; from the
table were reportID pulls information from did I write down the
correct field information? Can anyone help me out?
Private Sub ReportID_DblClick(Cancel As Integer)
On Error GoTo handleErr
Select Case Me!ReportID
Case "Supply Plant Flour"
DoCmd.OpenReport "rptAllSupplyPlantFlour", acViewPreview, "",
"", acNormal
Case "Supply Plant Oil"
DoCmd.OpenReport "rptAllSupplyPlantOil", acViewPreview, "",
"", acNormal
Case "Supply Plant Honey"
DoCmd.OpenReport "rptAllSupplyPlantHoney", acViewPreview, "",
"", acNormal
Case "Supply Plant Molasses"
DoCmd.OpenReport "rptAllSupplyPlantMolasses", acViewPreview,
"", "", acNormal
Case "Supply Plant Sugar"
DoCmd.OpenReport "rptAllSupplyPlantSugar", acViewPreview, "",
"", acNormal
Case "Supply Plant Corn Sryups"
DoCmd.OpenReport "rptAllSupplyPlantHFCS", acViewPreview, "",
"", acNormal
Case Else
End Select
exithere:
Exit Sub
handleErr:
Select Case Err.Number
Case Else
MsgBox "Error" & Err.Number & ":" & Err.Description,
vbCritical
End Select
GoTo exithere
End Sub
Ryan
ReportID, I have an event procedure on dbl click. But when I dbl click
the selection nothing happens. I have 2 columes of information that is
shown in the list box, column 1 has report name, column 2 has report
description. I put the report name in the case selection; from the
table were reportID pulls information from did I write down the
correct field information? Can anyone help me out?
Private Sub ReportID_DblClick(Cancel As Integer)
On Error GoTo handleErr
Select Case Me!ReportID
Case "Supply Plant Flour"
DoCmd.OpenReport "rptAllSupplyPlantFlour", acViewPreview, "",
"", acNormal
Case "Supply Plant Oil"
DoCmd.OpenReport "rptAllSupplyPlantOil", acViewPreview, "",
"", acNormal
Case "Supply Plant Honey"
DoCmd.OpenReport "rptAllSupplyPlantHoney", acViewPreview, "",
"", acNormal
Case "Supply Plant Molasses"
DoCmd.OpenReport "rptAllSupplyPlantMolasses", acViewPreview,
"", "", acNormal
Case "Supply Plant Sugar"
DoCmd.OpenReport "rptAllSupplyPlantSugar", acViewPreview, "",
"", acNormal
Case "Supply Plant Corn Sryups"
DoCmd.OpenReport "rptAllSupplyPlantHFCS", acViewPreview, "",
"", acNormal
Case Else
End Select
exithere:
Exit Sub
handleErr:
Select Case Err.Number
Case Else
MsgBox "Error" & Err.Number & ":" & Err.Description,
vbCritical
End Select
GoTo exithere
End Sub
Ryan