![]() Robin,Are you using VB6 and the Listview control from that? If memory serves me correctly, the listitems and subitems are 0 based collections. ![]() Here is code 2005:Debug.Print(ListView1.Items(0).SubItems(0).Text)ListView1.Items(0).SubItems(0).Text = 'foo'Adam BradenVisual Basic Team. So if you have 3 columns, they should be indexed 0-2.VB6:Debug.Print ListView1.ListItems(0).SubItem(0).TextDebug.Print ListView1.ListItems(0).SubItem(2).TextIf you are using Visual Basic 2005, then you need to change your code since the new control has an Items collection, not a ListItems collection. Edit Listview Subitem In Vb6 Shell Download Or Loop through the listview and search for text inside specific column.How you are populating the listview? What I want to add to this function is to update the quantity of a specific ID without clicking on the specific row in listview but by searching the ID, returning its results in the textbox, update it.I guess your best choice is to find ID using the (Key) but that depends on how you are populating the Listview. What the data has is ID number follow name and QTY. ![]() Hi guys,Currently I am updating a listview with data in it via clicking on the selected row and displaying that row data onto textboxes and then updating it. Private Sub ListView1DoubleClick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ListView1.DoubleClickIf = 0 ThenMsgBox('No Item In The List')Exit SubEnd Ifslist = ListView1.SelectedItems(0)txtItemName.Text = slist.SubItems(1).TexttxtQty.Text = slist.SubItems(2).TextEnd Sub. What I want to add to this function is to update the quantity of a specific ID without clicking on the specific row in listview but by searching the ID, returning its results in the textbox, update it. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |