title: Faster Userform Listbox filtering Excel VBA
body: <p>I'm developing a userform, and have a listbox in it. I'm loading the listbox, but only with select data, and based on different dropdowns in the userform as well. The sample sheet I have goes through 6000 lines, but I'm being told that it will eventually include 20,000+. It's already taking around ten seconds to filter. Is there a more efficient way of doing this? </p>
  
  <p>Code is below:</p>
  
  <pre><code>For rowNum = isStartRow To isEndRow
  
      Dim h2T As String: h2T = iSH.Range(h2 &amp; rowNum).Text
      Dim h3T As String: h3T = iSH.Range(h3 &amp; rowNum).Text
      Dim h4T As String: h4T = iSH.Range(h4 &amp; rowNum).Text
      Dim h5T As String: h5T = iSH.Range(h5 &amp; rowNum).Text
      Dim descT As String: descT = UCase(iSH.Range(desc &amp; rowNum).Text)
  
      If h2T Like "*" &amp; Me.cmbo_H2.value &amp; "*" And h3T Like "*" &amp; Me.cmbo_H3.value &amp; "*" And h4T Like "*" &amp; Me.cmbo_H4.value &amp; "*" And h5T Like "*" &amp; Me.cmbo_H5.value &amp; "*" And descT Like "*" &amp; UCase(Me.txt_Search.value) &amp; "*" And (iSH.Range("A" &amp; rowNum) = 10 Or iSH.Range("A" &amp; rowNum) = 20) Then
  
          If Not Exists(Me.cmbo_H2, h2T) Then Me.cmbo_H2.AddItem h2T
          If Not Exists(Me.cmbo_H3, h3T) Then Me.cmbo_H3.AddItem h3T
          If Not Exists(Me.cmbo_H4, h4T) Then Me.cmbo_H4.AddItem h4T
          If Not Exists(Me.cmbo_H5, h5T) Then Me.cmbo_H5.AddItem h5T
  
          Me.list_Items.AddItem iSH.Range(desc &amp; rowNum).Text
          Me.list_Items.List(Me.list_Items.ListCount - 1, 1) = iSH.Range(codeCol &amp; rowNum).Text
          Me.list_Items.List(Me.list_Items.ListCount - 1, 2) = iSH.Range(iNumber &amp; rowNum).Text
          Me.list_Items.List(Me.list_Items.ListCount - 1, 3) = iSH.Range(moqCol &amp; rowNum).Text
  
      End If
  
  Next
  </code></pre>