Hi,
I wrote this code to make money in a column.
There are alternatives or corrections to the code to improve cycle times?
Lots of thanks in advanceCode:Option Explicit Sub Arr_ciclo_Column() Dim LastRow As Long Dim rng As Variant Dim DVal As Integer 'Ok DVal = Range("Q2").Value '12 LastRow = Range("E" & Rows.Count).End(xlUp).Row rng = Range("IV1:IV" & LastRow) 'Range Clear rng = Redim... Dim Ciclo As Long For Ciclo = 3 To UBound(rng) Step DVal rng(Ciclo, 1) = Evaluate("SUM(E" & Ciclo & ":" & "E" & Ciclo + DVal - 1 & ")") Next Range("P1:P" & LastRow) = rng End Sub




Reply With Quote
Bookmarks