【发布时间】:2017-06-21 04:01:18
【问题描述】:
我有一个 Excel 文件,其中包含跑步者进行 9 次中间检查的时间。因此,每个参与者的总次数为 9,但实际时间之间的大量条目是空格。如何删除每列中的空格?
我尝试转换为 txt 并执行以下操作但没有成功,因为列时间之间不再有任何分隔:
tr -d ' ' < input.txt > no-spaces.txt
tr -d '[:blank:]' < input.txt > no-spaces.txt
tr -d '[:space:]' < input.txt > no-spaces.txt
https://askubuntu.com/questions/537956/sed-to-delete-blank-spaces
我所追求的是以下内容:
【问题讨论】:
-
VBA 可以循环遍历列并通过 SpecialCells(xlCellTypeBlank) 删除空白。删除或可能排序(后者取决于时间是否始终按升序排列)。