Hi There,
Here is what I'm trying to do:
I have a combobox and 3 buttons associted with the combobox
1)add - Adds an entry
2)remove - Remove an entry
3)remove all - Removes all entries
Let's call these 4 objects a Group
I have 2 groups.
I can easily remove a group.
My problem is adding a group. Here is the code I'm using to Remove an entry:
Private Sub Rem1_Click()
ComboBox1.RemoveItem (ComboBox1.ListIndex)
ComboBox1.Value = ""
End Sub
Add and remove and remove all have similiar code. I can simply copy and paste a group using a Macro, but the Macro Code isn't copied and the names of the buttons are changed. So I would physically have to change the code to add another group. This is no good.
Some Thoughts I had, but don't know how to implement:
1) Have many comboboxes but only one add, remove, and remove all buttons. The add, remove, remove all buttons check to see which combobox is selected and manipulate that box, this way everything is soft it makes no difference what the combobox's name is.
Any Suggestions/ help would be appreciated.
Thank you in advance,
NoChoice
Here is what I'm trying to do:
I have a combobox and 3 buttons associted with the combobox
1)add - Adds an entry
2)remove - Remove an entry
3)remove all - Removes all entries
Let's call these 4 objects a Group
I have 2 groups.
I can easily remove a group.
My problem is adding a group. Here is the code I'm using to Remove an entry:
Private Sub Rem1_Click()
ComboBox1.RemoveItem (ComboBox1.ListIndex)
ComboBox1.Value = ""
End Sub
Add and remove and remove all have similiar code. I can simply copy and paste a group using a Macro, but the Macro Code isn't copied and the names of the buttons are changed. So I would physically have to change the code to add another group. This is no good.
Some Thoughts I had, but don't know how to implement:
1) Have many comboboxes but only one add, remove, and remove all buttons. The add, remove, remove all buttons check to see which combobox is selected and manipulate that box, this way everything is soft it makes no difference what the combobox's name is.
Any Suggestions/ help would be appreciated.
Thank you in advance,
NoChoice