How can I find a line-feed (alt + Enter) in a text cell in Excel and replace it with a space. When we save our Excel data to .csv and upload, our application bombs with this special character.
Sub Macro1()
Dim x
Dim c As Variant
x = Chr(10)
For Each c In Selection
c.Replace What:=x, Replacement:=" ", LookAt:=xlPart, _
SearchOrder:=xlByRows, MatchCase:=False
Next c
End Sub
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.