I am trying to optimise some data sorting code, the original code looks like it has been "written" through the use of excels "Record Macro" function.
The following is an example from the code.
Range("A12").Offset(z, 0).Select
Selec.Resize(Selection.Rows.Count, Selection.Columns.Count + (X2 - 1)).Select
Selection.Copy
Range("C4").Offset(y, 0).Select
ActiveSheet.Paste
In order to make this code more efficient, should i re-write this section to involve a range variable that its' .Value is equal to the Selection data?
The X2, z and y variables are used as part of the copy function and are slowly increased to make reading the end product much easier. They are altered elsewhere in the module.
I would just like to see some suggestions for what you think I should do.
I have read the very popular "How to avoid using Select in Excel VBA Macros" question on here, and am just looking for some further advice.
(How to avoid using Select in Excel VBA macros)
Thanks