Reputation: 791
In Cell B6 there is number 1 and its color is red. but other cells are not red and there is no any data in them. after executing the following code, from B6 to B18, will be filled with numbers 1 ~ 13 but here there is a problem! i don't want to copy red color of B6 to B7 ... B8 ... B9 ... and ... i just need to copy without format of the base cell...
Range("B6").FormulaR1C1 = "1"
Range("B6").AutoFill Destination:=Range("B6:B18"),Type:=xlFillSeries
Can i find something like this property: xlFillSeriesWithoutFormat or a way to do this?
Upvotes: 0
Views: 2679
Reputation: 5687
According to the MS Docs*, it seems that xlFillValues
would be your best bet:
Copy only the values from the source range to the target range, repeating if necessary.
All the other options explicitly state that they will copy formatting. It looks like your only options are:
.AutoFill
*found by a Google search for "excel vba .autofill"
Upvotes: 1