iambadatexcel
New Member
hello everyone! hoping I can get some help with a macro formula. It is the macro called 'AddMulitRows'. It is supposed to take column I and duplicate it by the value in column I, how would I get it to duplicate it by the value in column I minus 1? Current formula below, spreadsheet attached for reference.
>>> use code - tags <<<
>>> use code - tags <<<
Code:
Sub AddMulitRows()
Dim i As Long
For i = Range("I" & Rows.Count).End(xlUp).Row To 2 Step -1
Rows(i).Copy
Rows(i).Resize(Range("I" & i)).Insert
Next i
End Sub
Attachments
Last edited by a moderator: