title: C# Is there a way to search through all listview items with a textbox?
body: <p>I have developed an application which populates a Listview through a SQL CE connection. I already have the insert, update and delete functions in it. The only thing that's left is the search function. I thought it was the easiest part, but I am searching for 2 days now and haven't found a good tutorial on this, so I thought someone on StackOverflow could help me.</p>
  
  <p>I have managed to search through the first item (main item, "PrincipalID") and I also want to search through the subitems. What I want is like</p>
  
  <pre><code>Principal ID    Email Address                     Subject                  Filename
  193490          test@test.com                     Exec OUT (report)        q9193.xls
  153130          test@test.com                     Standard mail Report     q7389.xls
  </code></pre>
  
  <p>What I now have is that I can search for principal numbers, but what I also want is to search for words, for example if I type "test" in the textbox, that I will get the record with the Email Address = "test@test.com" on top, or what would be better is that it will only show that record and hide the rest and then if the textbox is empty, that it shows all the records again.</p>
  
  <p>So basically I want to search the WHOLE listview for the string that is typed in the search textbox.</p>
  
  <p>Hopefully someone can help me,</p>
  
  <p>I will appreciate it from the bottom of my heart.</p>
  
  <p>Thanks in advance!</p>