下面是人家提供給我的
有幾各地方看不太懂
想問一下為什麼Do While one= two 下面還要加
A = A + 1
two = Cells(A, 3).Value
這兩行?
最後一各loop的上面為何還要加
A = A + 1
Sub 插入一行()
Dim A As Long, one As Variant, two As Variant
A = 5
Do While Cells(A, 3).Value <> ""
one = Cells(A, 3).Value
A = A + 1
two = Cells(A, 3).Value
Do While one = two
A = A + 1
two = Cells(A, 3).Value
Loop
ActiveSheet.Rows(A).Insert
A = A + 1
Loop