去编号VBA
'^ 匹配输入字符串的开始位置。
'$ 匹配输入字符串的结束位置。
Sub test()
Set regx = CreateObject("vbscript.regexp")
With regx
.Global = True
.Pattern = "^+\d+$"
For Each Rng In
Set mat = .Execute(Rng)
For Each m In mat
n = n + 1
Cells(n, 2) = m
Next
Next
End With
End Sub
页:
[1]