Copy information from other sheets to one special sheet.

P

Paul

Hi,
can u help me?

My workbook consits of one sheet named Total, and different sheets
named jan03, feb03, mar03 and so on. A new sheet is made each month.
All month sheets has a summary column and a column indicating the
month (that is column A and B) and I want to copy the values (not the
formula used) from column A and B to the sheet named Total. The VBA
code should always start copy information on sheet nr 2 from left
(sheet nr 1 is always Total followed by jan03, feb03, mar03...).

It is not predefined how many rows each month sheet has. It can be 2
rows for jan03, and 100 for feb03. The VBA code should therefore copy
information from the first row used (always row 10) and to the last
row used.

The sheet named Total should look like

Column A Column B
12 jan03
10 jan03
28 jan03
4 feb03
19 mar03
69 mar03
39 mar03
59 mar03
34 apr03


So far my VBA code looks like:

Sub Update_Total()
Sheets("Total").Select
Range("A1:IV65536").Select
Selection.ClearContents

Dim i%, SheetArg$()
ReDim SheetArg$(2 To Worksheets.Count -0)
For i = 2 To Worksheets.Count -0
'I'm not sure what to write here....
Next i
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top