rdoulaghsingh
Board Regular
- Joined
- Feb 14, 2021
- Messages
- 105
- Office Version
- 365
- Platform
- Windows
I'm using the below script to remove only blank line breaks using Chr(10). It works great, except that it doesn't remove the line break when it occurs at the beginning of the cell. I only need it to remove the first line break carriage from the top of the cell.
Any help is appreciated! Thanks!
VBA Code:
Sub RemoveBlankLines()
Columns("W").Replace What:=Chr(10) & Chr(10), Replacement:=Chr(10), _
LookAt:=xlPart, SearchFormat:=False, ReplaceFormat:=False
End Sub
Any help is appreciated! Thanks!