txt="陈峰经理0573-1234241"
for i=1 to len(txt)
if IsNumeric(mid(txt,i,1)) then exit for
next
phone=right(txt,len(txt)-i+1)
address=left(txt,i-1)
Private Sub Command1_Click()
a = "陈峰经理0573-1234241"
For i = 1 To Len(a)
If IsNumeric(Mid(a, i, 1)) Then
b = Left(a, i - 1)
c = Mid(a, i)
Exit For
End If
Next
Print "名字:" & b
Print "电话:" & c
End Sub
请参考。
个人极度建议你查一下vb中正则表达式的用法