When the below macro is ran, the memory unavailable error occurs causing it to terminate the execution abruptly.
Below code is the replica of the manual steps that we must do in order to preserve the conditional formatting formulas for arrow for Trend Analysis.
Please suggest a work around to this issue
wsh.Cells(2, col).EntireColumn.Insert
wsh.Cells(2, col).EntireColumn.Value = wsh.Cells(2, col + 1).EntireColumn.Value
wsh.Cells(2, col).EntireColumn.Hidden = True
wsh.Cells(2, col + 1).EntireColumn.Value = wsh.Cells(2, col + 2).EntireColumn.Value
Or
'Columns(col).Select
'Cells(2, col).EntireColumn.Select
'Selection.Copy
'Selection.Insert Shift:=xlToRight
'Cells(2, col).EntireColumn.Hidden = True
'Cells(3, col + 2).EntireColumn.Copy Cells(3, col + 1).EntireColumn