David
Macro solution OK?
Sub InsertRow_At_Change()
Dim i As Long
With Application
.Calculation = xlManual
.ScreenUpdating = False
End With
For i = Cells(Rows.Count, 3).End(xlUp).Row To 2 Step -1
If Cells(i - 1, 3) < Cells(i, 3) Then _
Cells(i, 3).Resize(1, 3).EntireRow.Insert
Next i
With Application
.Calculation = xlAutomatic
.ScreenUpdating = True
End With
End Sub
Assumes the ID numbers are in column C. If in another column, change the 3's
in the code to whatever column number you need.
Gord Dibben Excel MVP
On Wed, 4 May 2005 06:55:34 -0700, "David Noel" wrote:
I have a spreadsheet with a unique identifier for each
customer, Customer Information File (CIF). Whenever this
number changes, I want to automatically insert a blank
row. This will merely making the the spreadsheet more
pleasing to the eye to read. Keep in mind, there may not
be a break in CIF for 1 to 15 lines, but whenever this
CIF number changes, I want a new blank row.
Any help would be greatly appreciated!!
David
|