Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
UserForm2 allows user to enter maintenance records for a vehicle.
There is potentially more than 1 vehicle. The user will select a vehicle shown in ListBox2. The list of vehicles comes from range “VehicleMake” in sheet Vehicle Summary. Also, each vehicle on that same list has its own range name. V__1, V__2, etc thru V__10. Each of these range names contain no data until the user Adds another vehicle, which is done via another UserForm prior to using this UserForm. When a new vehicle is added, a sheet is created for the new vehicle added. Sheet V #1 for the 1st vehicle added, sheet V #2 for the 2nd vehicle added, etc. The user fills out the rest of UserForm2, then clicks OK. What I need is for the data in UserForm2 to be entered in the correct sheet based on the selection of the vehicle in ListBox2. The problem I’m having is to decide how to direct the macro to look for the correct sheet to put the data in. Example, if the 1st vehicle is selected on the list in ListBox2, then the data should go to sheet V #1. When the macro looks at which vehicle was selected, I’m not sure if my coding should reference the whole range of vehicles “VehicleMake”, or if it should reference the range name of the 1st vehicle on the list, V__1. I’ve never used a ListBox in a UserForm before. Thanks j.o. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Deleting Rows Based Upon ListBox Selection | Excel Programming | |||
change combobox values one by one based on selection in multiselect listbox | Excel Programming | |||
Delete Row Based on Listbox Selection | Excel Programming | |||
Capture listbox selection to a cell in a different sheet | Excel Programming |