title: Formatting List of Text Strings in Excel
body: <p>I am trying to turn the font to red for the occurrences of a list of words in excel. So far, I am able to find a single word, but I need to search for a whole array. I am a newbie with VBA and struggling. So far, I've been able to find this as a solution, but it deals with finding a single string, "F1":</p>
  
  <pre><code>Sub test4String2color()
  Dim strTest As String
  Dim strLen As Integer
  strTest = Range("F1")
  For Each cell In Range("A1:D100")
  If InStr(cell, strTest) &gt; 0 Then
  cell.Characters(InStr(cell, strTest), strLen).Font.Color = vbRed
  End If
  Next
  End Sub
  </code></pre>
  
  <p>Edit: </p>
  
  <p>The cells I need highlighted have the items listed in comma separated format. For example, "Apple 1, Apple 3, Banana 4, Orange". The list of values to search from are in Different cells, "Apple", "Banana 4". I only want to highlight "Banana 4" because this is an EXACT match with the comma separated values. In the current formulation, the text that says "Apple 1" or "Apple 4" would be partially highlighted.  </p>
  
  <p>Edit 2: </p>
  
  <p><a href="https://i.stack.imgur.com/Ytcu0.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Ytcu0.jpg" alt="Examples"></a></p>
  
  <p>This is the actual format from my workbook:</p>
  
  <p><a href="https://i.stack.imgur.com/GtAos.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/GtAos.jpg" alt="Example 3"></a></p>