I have a cell in a table that says:
64123 , where there is some kind of empty space after 3. I thought it was empty space, so in my vba code I tried several ways to get this OUT space from the string, but not application.trim and replace .
With Cells(c.Row, 16) .NumberFormat = "General" v = Application.Trim(.Text) v = Replace(v, " ", "") Debug.Print v .Clear .NumberFormat = "General" .Value = Application.Trim(v) End With
In the end, of course, there is empty space - I see this when I select a cell in Excel, and application.trim ALWAYS works for me. What else could be other than empty space? If it returns a tab or a carriage, what is the replace syntax for them for?
source share