infinity
10-12-2009, 05:04 PM
Hello everyone,
I am trying to insert rows at the top of one worksheet based on data that is on another worksheet. Example, if I have 150 records on one sheet I want to insert 150 rows at the top of the other sheet to move the data that is already there down and put the new data at the top. Any suggestions? I tried this, but it does not work (no surprise there)...
lastRow = range("B" & Rows.Count).End(xlUp).Row
Range("1:1").Insert Shift:=xldown range("1:1" & lastrow)
Thank you!
I am trying to insert rows at the top of one worksheet based on data that is on another worksheet. Example, if I have 150 records on one sheet I want to insert 150 rows at the top of the other sheet to move the data that is already there down and put the new data at the top. Any suggestions? I tried this, but it does not work (no surprise there)...
lastRow = range("B" & Rows.Count).End(xlUp).Row
Range("1:1").Insert Shift:=xldown range("1:1" & lastrow)
Thank you!