This document contains code for adding and removing items from two listboxes using input boxes and commands. It allows adding items to each listbox, removing items from each listbox by index or text, and attempting to remove items between the two listboxes.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
17 views1 page
List Box
This document contains code for adding and removing items from two listboxes using input boxes and commands. It allows adding items to each listbox, removing items from each listbox by index or text, and attempting to remove items between the two listboxes.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1
listbox
Private Sub Command1_Click()
Dim listitem As String listitem = InputBox("enter the element to be added to list 1") If Trim(listitem) <> "" Then End If End Sub Private Sub Command2_Click() Dim listitem As String listitem = InputBox("enter the element to be added to list 2") If Trim(listitem) <> "" Then End If End Sub Private Sub Command3_Click() List1.RemoveItem List1.ListIndex End Sub Private Sub Command4_Click() List2.RemoveItem List2.Text End Sub Private Sub Command5_Click() List1.RemoveItem List2.Text End Sub Private Sub Command6_Click() List2.RemoveItem List1.Text End Sub Private Sub Command7_Click() End End Sub Private Sub Form_Load() List1.AddItem "PRINTER" List2.AddItem "MOUSE" End Sub