Userform-how to dynamically update listboxes based on select

anduls

New Member
Joined
Dec 13, 2005
Messages
1
I’m trying to find the best approach for the following:

I’m working on Userform which is some sort of system design tool.
I have limited choice of items to select (less than 10) and limited capacity of how many items can be selected (limited number of slots where those items fit in). There are also conditions like:
1) Some of items will take one slot space, some will take two
2) Some items you can have only one per system, some two some without limitation.

My idea was to use number of listboxes where user selects items needed. There is no problem to populate the listbox with items, but I’m not sure about how to update following listboxes based on choices user has already made and limits and rules I described earlier.

~anduls
 

Some videos you may like

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.

Dragon_SDC

Board Regular
Joined
Aug 17, 2002
Messages
56
Suppose your main listbox was named Box1. In the code for the form add:
Code:
Private Sub Box1_Change()

'Code to do stuff with other listboxes goes here

End Sub

This will be run when you change the selected item in your mail listbox.


HTH
 

Watch MrExcel Video

Forum statistics

Threads
1,118,331
Messages
5,571,578
Members
412,407
Latest member
ElmerCC
Top