Copy to wildcard
those look more like workbook names not sheet names but i'm going by what you said
Sub CopyData(
LstClmn = Sheets("052107.xls").UsedRange.Offset
(0, ActiveSheet.UsedRange.Columns.Count - 1).
Resize(, 1).Colum
x = YourRowCoun
Mnth =Cstr( Format(Now,"mmm")) '<< assuming you use three letter abbreviation for each month
Sheets.("summary_" & Mnth &".xls"). Range(Cells(1,1), Cells(x,LstClmn)) =
Sheets("052107.xls").Range(Cells(1,1), Cells(x,LstClmn)
End Su
----- Richard wrote: ----
Greetings
I am copying data from a daily worksheet (052107.xls) to a monthly summary (summary_may.xls), the data on the daily sheets will have the same number of rows but different numbers of columns. How can I copy the used range on the daily summary sheet to the monthly sheet
Thanks
Richard
|