Find partial text from Subitem in ListViewItem

Hi there.
I have struggeled a lot the last weeks, trying to get my search engine for my program to work, with no luck.
I tried different methods like FindItemWithText, but it will not work.

My challenge is that I have a textbox (txtSok) for the search word, and a new ListViewItem (frmTelefon) that I will populate with the result from my search.
The search routine are using data from another ListViewItem on another form (frmOPS).

I would like to have the searched done by using the TextChanged on txtSok.

My frmOPS have 5 columns, but the search is going to look for items similar to txtSok.Text in column 2.

Can anyone give me some good advice? Is any of my code interesting to see for you??
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Dirk HaestProject managerCommented:
here you can find a very interesting article about this subject:

How to: Add Search Capabilities to a ListView Control
Dirk HaestProject managerCommented:
This bit of code lets you search for ListView items and subitems by typing in the first few characters

Search for ListView items, subitems,295339,sid8_gci1173206,00.html

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
VikingS6Author Commented:
It didn't work 100% with my project. I got some error trying to use the type ListItem and the function FindItem.
My VB2008 Express Edition didn't recognized these.

But from your example code, I was able to tune it a bit, and in combination with the use of the function InStr, I managed to solve my search problem.

Works OK - and that's good enogh for me.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.