Is there a faster way to go through a string to detect if there are illegal characters? This is what I am using right now.
Thank You
Code:Option Explicit Sub Main() 'PURPOSE: Test Data Dim str_Data As String str_Data = "How are you today?" 'PURPOSE: Illegal Characters Dim str_IllegalChar As String str_IllegalChar = "\/:*?""<>|" Dim str_Char As String Dim int_X As Integer For int_X = 1 To Len(str_Data) str_Char = Mid(str_Data, int_X, 1) If InStr(1, str_IllegalChar, str_Char) <> 0 Then MsgBox str_Char End If Next End Sub


Reply With Quote
