How to remove spaces in between text?

后端 未结 10 571
日久生厌
日久生厌 2021-01-13 00:00

Why trim is not working in VBA?

for i = 3 to 2000
activesheet.cells(i,\"C\").value = trim(Activesheet.cells(i,\"C\").value)
next i

It is un

10条回答
  •  隐瞒了意图╮
    2021-01-13 00:45

    My related issue was that the last character was a chr(160) - a non-breaking space. So trim(replace(Str,chr(160),"")) was the solution.

提交回复
热议问题