View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Gary''s Student Gary''s Student is offline
external usenet poster
 
Posts: 11,058
Default Select cells copy/paste and repeat x times

One approach is to standardize the column. For example:

A month like July has 31 days. If you have hourly sample for 24 hours, you
would have 744 samples for July (if you only sample over 8 hours, then 248
samples).

Even though a month like June has only 30 days, leave room in the data for
the missing 31st day. You would leave that day's data empty.

In that way you could copy/paste a fixed number of cells for all months.
--
Gary's Student


"Mike Hann" wrote:

I am new to scripting in excel and need some help.

I have a sheet where there is data in a cell for each hour of the day
repeating for each day of the month (in a column). I need to copy the data
for each day into a separate worksheet (in a column) then the next day into
another column.

I have done this using a recorded macro but this doesn't always work
correctly as the months have different numbers of days.

The data is always for the previous month from the current month.

Any help or advise much appreciated.