On Error GoTo Err_cmdRunReport_Click
[red]
Dim oFS As Object
Dim strFilename As String
[/red]
Dim stDocName As String
Dim strWhere As String
If Not IsNull(Me.List37) Then
Select Case Me.List37
Case Else
' strWhere = strWhere & BuildWhere()
stDocName = Me.List37
DoCmd.OpenReport stDocName, acPreview, , strWhere
DoCmd.Maximize
Me.Visible = False
[red]
strFilename = "filename.html"
Set oFS = CreateObject("Scripting.FileSystemObject")
Me.TextBox = oFS.getfile(strFilename).datelastmodified
Set oFS = Nothing
[/red]
End Select
Else
MsgBox "You must select a report", vbOKOnly + vbInformation, "Select Report"
Me.List37.SetFocus
End If
Exit_cmdRunReport_Click:
Exit Sub
Err_cmdRunReport_Click:
Select Case Err.Number
Case 2501 'ignore
Case Else
MsgBox Err.Description
End Select
Resume Exit_cmdRunReport_Click
On Error GoTo 0
Exit Sub
cmdRunReport_Click_Error:
MsgBox "Error " & Err.Number & " (" & Err.Description & ") in procedure cmdRunReport_Click of VBA Document Form_frmReportSelection"
End Sub