vb.net avoid listview duplicate -
My LvList is the code to clone my LvPrint My problem is to avoid duplicate or to prevent duplicate help < / P>
Dim Lively, Lavi 2 View as the new list if lv list. Selected items. Mount & gt; For 0 then I list the lv as integer = 0. Selected Items. Number - 1 lvi = lv list Select item (i) lvi2 = CType (lvi.Clone, ListViewItem) lvPrint.Items.Add (lvi2) Next End if
<
"post-text" itemprop = "text"> < Blockquote>
Check it below, additional added if position lvprint
dim lvi, lvi2 new list view form to check the already selected string In the dim list string = "" String = "Dim Printslist" as J = integer = 0 to lvPrint.Items.Count- 1 printlist = printlist & amp; ; "" & Amp; LvPrint.Items (j). Next Next if lvList.SelectedItems.Count & gt; For 0 then I call the lv as integer = 0. Selected Items. Number - 1 lvi = lv list The selected item (i) if the list is not listed.Configuration (lvi.Text) and not printlist.Contains (lvi.Text) then lvi2 = CType (lvi .CLone, ListViewItem) lvPrint.Items.Add (lvi2) closing if list = List & amp; "" & Amp; Lvi.Text Next End if
Comments
Post a Comment