For the life of me..i cannot figure this out.
VB Code:
intItemCount = Form1.ListView.ListItems.Count For a = 1 To intItemCount WhoMsg = GetText(Form1.List1.List(a - 1)) Umsg = Split(WhoMsg, ":") TuMsg = Umsg(0) If InStr(Form1.ListView.ListItems.Item(a).Text, TuMsg) Then Form1.ListView.ListItems.Item(1).ListSubItems.Item(a).Text = Form1.ListView.ListItems.Item(1).ListSubItems.Item(a).Text + 1 End If Next a
This bit of code, checks to see the listview item contains the classname (which TuMsg is). It works the first time around (and adds 1) but after that this: Form1.ListView.ListItems.Item(1).ListSubItems.Item(a).Text: gives me an index out of bounds error (there are 2 items)
I hope you understood, and i hope this is real easy





Reply With Quote