title: Remove special characters in excel vba
body: <p>I am using this function to remove all supposed special character but still few special characters like "Ø" or "é" and all similar characters are still there How to handle this also in below given function.</p>
  
  <p>What is in my mind is that to also create a string of those special characters like MyStr and to remove them.</p>
  
  <p>Please suggest.</p>
  
  <pre><code> Function ReplaceSplChars(TempStr As String) As String
  
  Dim counter As Long, Position As Long
  Dim MyStr As String, SplStr As String
  
  
  MyStr = " 1234567890abcdefghijklmnopqrstuvwxyz.@"
  Position = 1
  
  For counter = 1 To Len(TempStr)
      SplStr = Mid(LCase(TempStr), Position, 1)
  
      If Not InStr(MyStr, SplStr) &gt; 0 Then
  
          If SplStr = "-" Or SplStr = "_" Or SplStr = "'" Or SplStr = "/" Or SplStr = "," Then
              TempStr = Replace(TempStr, SplStr, " ", , 1)
              SplCharCount = SplCharCount + 1
              Position = Position + 1
          Else
              TempStr = Replace(TempStr, SplStr, "", , 1)
              SplCharCount = SplCharCount + 1
          End If
      Else
         Position = Position + 1
      End If
  
  Next counter
  ReplaceSplChars = TempStr
   End Function
  </code></pre>