【发布时间】:2015-08-24 22:15:22
【问题描述】:
函数allows列出的字符(在这种情况下)
Case 48 To 57, 65 To 90, 97 To 122:
是否可以将其更改为Remove 列出的字符?
谢谢
Function AlphaNumericOnly(strSource As String) As String
Dim i As Integer
Dim strResult As String
For i = 1 To Len(strSource)
Select Case Asc(Mid(strSource, i, 1))
Case 48 To 57, 65 To 90, 97 To 122:
strResult = strResult & Mid(strSource, i, 1)
End Select
Next
AlphaNumericOnly = strResult
End Function
【问题讨论】: