L
Lee Jeffery
Using Excel 97 on WINNT
Each fortnight I receive a report which is then formatted and save
using a dated filename for the next Wednesday e.g. "570 Repor
28-07-2004".
Next period, this report will be automatically saved as 570 Repor
11-08-2004". I use the code:
"G:\ER\570 report " & Format(date+4-weekday(date), "dd-mm-yyyy")
".xls"
which was kindly supplied by Dave Peterson.
I am now trying to compare fortnightly reports and was wondering i
there is a way to call the current report and the previous fortnightl
report using VBA as part of a macro? If so, during the comparison o
the two workbooks, I would need to differentiate between them by usin
code such as: CompareWorksheets ActiveWorkbook.Worksheets("Sheet1"), _
Workbooks("570 Report 28-07-2004.xls").Worksheets("Sheet1")
although this will only work for the named report. Is there a way tha
VBA can call the previous report without knowing its full name?
These reports will only be called on the Monday or Tuesday immediatel
prior to the Wednesday date appearing in the most recent file name an
will only want to call the current report and the previous fortnightl
report so there is no need to go any further back in time.
Can anyone help, please?
TIA.
Lee :
Each fortnight I receive a report which is then formatted and save
using a dated filename for the next Wednesday e.g. "570 Repor
28-07-2004".
Next period, this report will be automatically saved as 570 Repor
11-08-2004". I use the code:
"G:\ER\570 report " & Format(date+4-weekday(date), "dd-mm-yyyy")
".xls"
which was kindly supplied by Dave Peterson.
I am now trying to compare fortnightly reports and was wondering i
there is a way to call the current report and the previous fortnightl
report using VBA as part of a macro? If so, during the comparison o
the two workbooks, I would need to differentiate between them by usin
code such as: CompareWorksheets ActiveWorkbook.Worksheets("Sheet1"), _
Workbooks("570 Report 28-07-2004.xls").Worksheets("Sheet1")
although this will only work for the named report. Is there a way tha
VBA can call the previous report without knowing its full name?
These reports will only be called on the Monday or Tuesday immediatel
prior to the Wednesday date appearing in the most recent file name an
will only want to call the current report and the previous fortnightl
report so there is no need to go any further back in time.
Can anyone help, please?
TIA.
Lee :