ultracyclist
Active Member
- Joined
- Oct 6, 2010
- Messages
- 274
- Office Version
- 365
- Platform
- Windows
In Column B, I have repeating cell values. I would l like to insert a blank row whenever the value changes.
I found the following code which targets only a single value. I tried modifying this to meet my needs, but not sure.
</o>
<o></o>
<o></o>
<o>Any thoughts?</o>
<o></o>
<o>Thanks,</o>
<o></o>
<o>Allen</o>
I found the following code which targets only a single value. I tried modifying this to meet my needs, but not sure.
Rich (BB code):
Sub InsertRows()
Dim i As Long
i = 2
Do Until Trim(Cells(i, 1)) = ""
If Cells(i, 1) = "991CX" Then
Cells(i, 1).EntireRow.Insert
i = i + 2
Else
i = i + 1
End If
Loop
End Sub<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
<o:p></o:p>
<o:p>
<o></o>
<o></o>
<o>Any thoughts?</o>
<o></o>
<o>Thanks,</o>
<o></o>
<o>Allen</o>
Last edited by a moderator: