Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
I have the following code:
Private Sub CommandButton7_Click() UserForm1.ListBox2.Add("A", "B", "C") End Sub I am having trouble with line 2. Im not sure how to add the "A", "B" and C in userform 1 listbox by clicking command button 7. |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Is this commandbutton on the same userform as the listbox?
Private Sub CommandButton7_Click() with me.ListBox2 .Additem "A" .additem "B" .additem "C" end with End Sub M&M wrote: I have the following code: Private Sub CommandButton7_Click() UserForm1.ListBox2.Add("A", "B", "C") End Sub I am having trouble with line 2. Im not sure how to add the "A", "B" and C in userform 1 listbox by clicking command button 7. -- Dave Peterson |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
The command button is not in the same userform as the listbox. The command
button is in Userform2 and the listbox2 is in Userform 1. Is this gonna be a problem? "Dave Peterson" wrote: Is this commandbutton on the same userform as the listbox? Private Sub CommandButton7_Click() with me.ListBox2 .Additem "A" .additem "B" .additem "C" end with End Sub M&M wrote: I have the following code: Private Sub CommandButton7_Click() UserForm1.ListBox2.Add("A", "B", "C") End Sub I am having trouble with line 2. Im not sure how to add the "A", "B" and C in userform 1 listbox by clicking command button 7. -- Dave Peterson |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Change the
with me.listbox2 back to with userform1.listbox2 M&M wrote: The command button is not in the same userform as the listbox. The command button is in Userform2 and the listbox2 is in Userform 1. Is this gonna be a problem? "Dave Peterson" wrote: Is this commandbutton on the same userform as the listbox? Private Sub CommandButton7_Click() with me.ListBox2 .Additem "A" .additem "B" .additem "C" end with End Sub M&M wrote: I have the following code: Private Sub CommandButton7_Click() UserForm1.ListBox2.Add("A", "B", "C") End Sub I am having trouble with line 2. Im not sure how to add the "A", "B" and C in userform 1 listbox by clicking command button 7. -- Dave Peterson -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
If - easy question | Excel Discussion (Misc queries) | |||
*EASY* question! | New Users to Excel | |||
new user with easy question? not easy for me | New Users to Excel | |||
easy question | Excel Worksheet Functions | |||
easy question .... i think | Excel Discussion (Misc queries) |