MACRO FOR INSERTING ROWS AND PASTING VALUES
Posted by EDDIE G on October 23, 2001 10:58 AM
I currently have a variation of what I need but I cannot figure out how to change it for my current need. I need a macro that will insert rows starting at row three to end of worksheet, then cut and paste E2:G2 into B3, and so forth and so on through the whole worksheet. Below is the code I use for a similar two-column sheet. I am certain a simple change to the below code will work. Can someone help please?
Sub WEIGHT_PLACER()
Dim rng As Range, nextBlank As Range
Set rng = Range(Range("A2"), Range("A65536").End(xlUp))
Columns("C").Insert
Range("C2").Value = 1
rng.Offset(0, 2).DataSeries
Columns(2).Insert
Range("B2").Value = 1
rng.Offset(0, 1).DataSeries
Set nextBlank = Range("A65536").End(xlUp).Offset(1, 1).Resize(1, 2)
Range(rng.Offset(0, 3), rng.Offset(0, 4)).Copy nextBlank
Columns("A:C").Sort Key1:=Range("B1"), Order1:=xlAscending, Header:=xlYes
Range("B:B,D:E").Delete
End Sub