title: Check if a string contains an element from a list (of strings)
body: <p>For the following block of code:</p>
  
  <pre><code>For I = 0 To listOfStrings.Count - 1
      If myString.Contains(lstOfStrings.Item(I)) Then
          Return True
      End If
  Next
  Return False
  </code></pre>
  
  <p>The output is:</p>
  
  <p><strong>Case 1:</strong></p>
  
  <pre class="lang-none prettyprint-override"><code>myString: C:\Files\myfile.doc
  listOfString: C:\Files\, C:\Files2\
  Result: True
  </code></pre>
  
  <p><strong>Case 2:</strong></p>
  
  <pre class="lang-none prettyprint-override"><code>myString: C:\Files3\myfile.doc
  listOfString: C:\Files\, C:\Files2\
  Result: False
  </code></pre>
  
  <p>The list (listOfStrings) may contain several items (minimum 20) and it has to be checked against a thousands of strings (like myString).</p>
  
  <p>Is there a better (more efficient) way to write this code?</p>