Repeating a cell value in Excel
This is a request I have had a number of times.. In excel you want to copy the value of the cell above your current position if your current position is blank
To start this macro click on a row 2 or lower with a value in the cell above, change the value of x in the macro to the number of lines you want ot repeat
Sub Macro1() ' ' change the value of x to the number of lines to fill Dim I, x x=1500 Do While I < x If ActiveCell.Value = "" Then ActiveCell.Offset(-1, 0).Select Selection.Copy ActiveCell.Offset(1, 0).Select ActiveSheet.Paste End If ActiveCell.Offset(1, 0).Select I = I + 1 Loop End Sub
Leave a ReplyWant to join the discussion?
Feel free to contribute!