View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Need help wiht a macro for autofill rows

Actually, this line:

myFormulaRng.Copy _
Destination:=.Cells(iRow, "H").Resize(HowManyPerGroup - 1)

copied that first row (2) with had the formulas to 22 rows all at once.

If you have calculation set to manual, then try calculating.



klafert wrote:

Oh and the last filled row of the spreadsheet is A10914-r10914. What you did
almost work but it copied all the same data in each row which is
understandable considering I said I was copying the same formula all the way
down, but skipping a linel - Sorry for being as clear as mud - Does this help
or change things until then I am copying and pasting, possible trying to
adjust the macro you wrote, if I can? Help!!

"klafert" wrote:

I should have said the 1st row A1.L1 is a header row - Starting with row a2 I
copy 22 rows, want to skip one row and copy 22 more rows and skip again etc.

"Dave Peterson" wrote:

And just add, I'd delete up the blank rows. Those blank rows really mess things
up when you're filtering, doing pivottables, creating charts, or sorting.

You may want to consider just doubling the row height to make it look nicer when
printed.

klafert wrote:

I have a spreadsheet that has 10915 lines. I am copying the same formula
from row 2 - columns H2..L2 to the next 21 rows then there will be one blank
row and I will copy the same columns for the next 21 rows - blank row again
and so on.

Example:

I highlight row 2 (column H2-L2) Fill down H2:L2 to h23:L23 then I have one
blank row and then I would copy H2-L2 thru H23-l23 to h25-L46 - Hope that is
clear enough for somebody to understand if not let me know.

--

Dave Peterson


--

Dave Peterson