作者mycircle (mycircle)
看板Office
标题Re: [算表] excel 删掉空格的方式
时间Fri Sep 7 01:00:45 2007
※ 引述《lame (生日快乐)》之铭言:
: 软体:
: excel
: 版本:2003
: 我需要把以下的空格删掉 就是让每一直直列的空格被删掉 顺序不变
: 由於有上万个数据 无法一一删 希望有好心人可以提供聪明的方法
: 1
: d
: d
: w
: d
: d
: e dfe
: e d ew
: cx
: c c
: -------我想要变成以下这样----------
: 1 d d
: w d d
: e d dfe
: e cx ew
: c c
范例下载
http://0rz.tw/7f32S
 ̄▽ ̄|| 抱歉 没有把它写很好 不过应该是堪用啦
如果你有更好的想法记得跟我说喔
Do
For x = 1 To 20
For y = 1 To 20
If Cells(x, y) = "" And Cells(x + 1, y) <> "" Then
Cells(x, y) = Cells(x + 1, y)
Cells(x + 1, y) = ""
End If
Next
Next
g = g + 1
Loop Until g = 400
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 59.104.167.7