date of last querytable refresh


Posted by Mark B on May 01, 2001 9:38 AM

I would like to have a title for a report read "as of:" and give a date representing the most recent update of the external data. Is there a way to retrieve the date from an imported text file and plop it into a cell? (or even better, into a header...)
Thanks for your time, gang. Hope you can help!
Mark B

Posted by Kevin James on May 01, 2001 9:57 AM

Hi Mark,

You can setup a blank (template) spreadsheet. In the template, insert the date/time into the header using:
View/Header and Footer
If there is not already a header or footer designed with the timestamp, press custom header (or footer). The clock icon places the time; the calendar icon places the date.

Use the template file to import your data dump.



Posted by Mark B on May 01, 2001 11:03 AM

Here's my solution for the next time I need it:
Response = Dir "F:\Database\Revenue\revenue.txt")
If Response <> "" Then
Response = FileDateTime("F:\Database\Revenue\revenue.txt")
Range("Forecast!M4").Select
ActiveCell.Value = Response

Else: MsgBox "there's no date on the revenue file!"
Exit Sub
End If

Thanks for your suggestion though...