Hi all,
I wanted to pose this challenge as I've experimented and failed, let me start with my current process.
To concatenate two ranges (combining a contiguous range of cells from columns "A" and "B") into a single range of cells I'm using variations on this process:
The "With" portion defines a dynamic range. The "FormulaR1C1" fills the cells with a formula returning the correct value, and the "Copy" / "Paste" steps hard-code those values.With Range("A2", Range("A2").End(xlDown)) .NumberFormat = "0" .FormulaR1C1 = "=RC[1]&RC[2]" .Copy .PasteSpecial Paste:=xlPasteValues End With
I have found I can achieve a better result (through fewer steps) on a cell-by-cell basis with the following:
But the only way I know to do this is by looping, which doesn't perform as well as the above method which can process a whole range in one "With" block.Range("A2") = Range("B2") & Range("C2")
As an experiment I attempted this:
But it doesn't work. If I can clear that hurdle I can apply it at least 20 times across my 3000 line macro, and get really complex. Can anybody help me?Range("A2:A3") = Range("B2:B3") & Range("C2:C3")