mjschukas
May 31 2012, 09:48 AM
i'm using (below) to fill a range of cells with the numbers and formulas in row 9 (works well):
Range("a9:bu9").AutoFill Destination:=Range("a9:bu" & myrow)
but i have one column that has the numerica value of 0 and i want this to copy down,
but instead, an arithmetic sequence copies down (0,1,2,3...)
what can i do to stop the sequence and just copy down the 0?
???
thank you.
ipisors
May 31 2012, 09:49 AM
Check out the help files regarding Range.Autofill method. specifically, xlAutoFillType
Bob G
May 31 2012, 09:51 AM
what you could do is copy the cell once. that would give you 2 cells with a 0. then use both of those to copy down. Because the cells are the same they would not increment as you are seeing.
ipisors
May 31 2012, 09:53 AM
Or just correctly use AutoFill....
CODE
Range("a9:bu9").AutoFill Destination:=Range("a9:bu" & myrow), Type:=xlFillCopy
mjschukas
May 31 2012, 12:09 PM
thank you...!
"works like a charm"
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.