E
Ed Peters
Hi all,
I am trying to insert and copy a number of rows according to a cell
value.
From the data below I would ignore all the 1's and if the number is
Londontt,4
Londontt,4
Londontt,4
Londontt,4
Orginal data below
London54 , 1
London44,1
London333,2
London77,1
London99, 5
London33,1
I can use the code below to loop.
Do Until IsEmpty(ActiveCell) = True
If ActiveCell.Value <> 1 Then
ActiveCell.EntireRow.Select
active.cell.Select
Selection.Insert
GoTo Continue
End If
ActiveCell.Offset(1, 0).Select
Loop
Continue:
Thanks,
Ed
I am trying to insert and copy a number of rows according to a cell
value.
From the data below I would ignore all the 1's and if the number is
be1, eg 4 then insert 3 rows (4-1) and copy the data, so result would
Londontt,4
Londontt,4
Londontt,4
Londontt,4
Orginal data below
London54 , 1
London44,1
London333,2
London77,1
London99, 5
London33,1
I can use the code below to loop.
Do Until IsEmpty(ActiveCell) = True
If ActiveCell.Value <> 1 Then
ActiveCell.EntireRow.Select
active.cell.Select
Selection.Insert
GoTo Continue
End If
ActiveCell.Offset(1, 0).Select
Loop
Continue:
Thanks,
Ed