i have a class "item" and this is how my class looks and how i populate" item"objects my listbox list1
VB Code:
public class item Public fname As String, pid As Long Public Sub New(ByVal id As Long, ByVal nm As String) fname = nm pid = id End Sub Public Overrides Function ToString() As String Return pid & vbTab & fname End Function end class Private Sub form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles form1.Load list1.items.add(new item(1,"myname")) End Sub
my question is how can i search for a particular object in the list provided my search criteria is the id ???




Reply With Quote