D
Daniel
Good morning,
I'm having a compatibility issue (I believe) between 2000 and 2003. I use
the following sub to open a selected report form a listbox.
Private Sub lstReports_DblClick(Cancel As Integer)
On Error GoTo lstReports_DblClick_Error
'Open report based on user selection
Dim strRptName As String
strRptName = Me.lstReports
If Not IsNull(strRptName) Then
If strRptName = "Drawings Forecasted per Week" Then
DoCmd.OpenForm "Forecast Rpt Date Selection Frm", acNormal
ElseIf Left(strRptName, 5) = "DRM -" Then
DoCmd.OpenForm "DRM Report Form", acNormal
Else
DoCmd.OpenReport Me.lstReports, acViewPreview
End If
End If
On Error GoTo 0
Exit Sub
lstReports_DblClick_Error:
MsgBox "MS Access has generated the following error" & vbCrLf & vbCrLf &
"Error Number: " & _
Err.Number & vbCrLf & "Error Source: Form_Report Selection Frm /
lstReports_DblClick" & vbCrLf & _
"Error Description: " & Err.Description, vbCritical, "An Error has
Occured!"
Resume Next
End Sub
It works fine for any user running on access 2000. It also workd fine on my
personal laptop running access 2003. However, a specific user running access
2003 keeps getting error 2501- The OpenReport action was cancelled. When she
work on another computer with 2000 it works. This leads me to believe it is
a 2003 thing?! But then why does it wok fine for me?
Another particular thing with her computer is the fact that she get prompted
with 3 dialogs when she open the db. A security warning about blocking
unsafe expressions, something a jet and then the standard message confirming
opening this file... The first 2 dialog do not appear for anyone else...
Is this a config issue with her pc? Does anyone know what might be the
problem in this case?
Is "DoCmd.OpenReport Me.lstReports, acViewPreview" an acceptable command in
both 2000 and 2003? or should I be using another command instead?
Thanking you in advance for your help,
Daniel
I'm having a compatibility issue (I believe) between 2000 and 2003. I use
the following sub to open a selected report form a listbox.
Private Sub lstReports_DblClick(Cancel As Integer)
On Error GoTo lstReports_DblClick_Error
'Open report based on user selection
Dim strRptName As String
strRptName = Me.lstReports
If Not IsNull(strRptName) Then
If strRptName = "Drawings Forecasted per Week" Then
DoCmd.OpenForm "Forecast Rpt Date Selection Frm", acNormal
ElseIf Left(strRptName, 5) = "DRM -" Then
DoCmd.OpenForm "DRM Report Form", acNormal
Else
DoCmd.OpenReport Me.lstReports, acViewPreview
End If
End If
On Error GoTo 0
Exit Sub
lstReports_DblClick_Error:
MsgBox "MS Access has generated the following error" & vbCrLf & vbCrLf &
"Error Number: " & _
Err.Number & vbCrLf & "Error Source: Form_Report Selection Frm /
lstReports_DblClick" & vbCrLf & _
"Error Description: " & Err.Description, vbCritical, "An Error has
Occured!"
Resume Next
End Sub
It works fine for any user running on access 2000. It also workd fine on my
personal laptop running access 2003. However, a specific user running access
2003 keeps getting error 2501- The OpenReport action was cancelled. When she
work on another computer with 2000 it works. This leads me to believe it is
a 2003 thing?! But then why does it wok fine for me?
Another particular thing with her computer is the fact that she get prompted
with 3 dialogs when she open the db. A security warning about blocking
unsafe expressions, something a jet and then the standard message confirming
opening this file... The first 2 dialog do not appear for anyone else...
Is this a config issue with her pc? Does anyone know what might be the
problem in this case?
Is "DoCmd.OpenReport Me.lstReports, acViewPreview" an acceptable command in
both 2000 and 2003? or should I be using another command instead?
Thanking you in advance for your help,
Daniel