I'm just wondering if there is a way to search a listview? Just need to know if there is already a function or something for it, I couldnt find anything myself....
Printable View
I'm just wondering if there is a way to search a listview? Just need to know if there is already a function or something for it, I couldnt find anything myself....
u mean serch a list box??
ListBox1.Items.Contains()
it will return true or false depending if it finds the thing or not
well, I'm trying to search in a ListView control, not a listbox. And I want to search in different ways:
search for a word with and without case sensivity
partial search and exact search
I guess I'll do it manually :D
Umm I just dont know how to check for case sensivity?:confused:
I think the string.compare() function.
this will compair with case sensitivity.
intReturnVal = string.Compare(string1, string2, true)
if intReturnVal = 0 Then
MessageBox.Show("They match case sensitivity")
end if
or without case sensitivity:
intReturnVal = string.Compare(string1, string2, false)
if intReturnVal = 0 Then
MessageBox.Show("They match but may not be a match as far as case goes")
end if
never noticed their was a list view as well :o
it has the same function but it wont work for parts of the words, u could use an iterator from the collection and the string functions, i think the string function do case sensitivity
worx much better than listbox :)Quote:
Originally posted by spike232
never noticed their was a list view as well :o
tnx alot hellswraith:)