List help

W

Warderbrad

I am needing to have a list populated with data dependant on the valu
chosen in another field. Basically when a person chooses a day of th
week I want to have the next field list the times of scheduled event
for them to choose one of. I have looked at the help file for how t
write a macro for the adding or modifying of data validations but th
examples when I put them into the code have errors even when copied an
pasted as they appear. I am confused about how to get this to work.
would like to avoid using a combo box or other control and would prefe
to have it be in the cell directly. Any help would be appreciated
 
W

Warderbrad

No, the number of items in a given day is variable based on the
avilability of moderators. I have solved the issue of compiling the
list of times by having a seperate table that uses a Concentate
statement to combine all times from the main table for refrence. So
using that work arround there is only one field for each day to pull
up.

Example of both tables

Sunday: 5-7 pm PST
Sunday: 9-11 pm PST
Monday: 4-6 pm PST

Would result to this in the second table

Sunday: 5-7 pm PST, 9-11 pm PST
Monday: 4-6 pm PST

My thought is if I could put the data from the second table into the
source field of the data validation using the list method, then the
commas would result in different items in the choosable list. However
I am having problems figuing out the syntax for the macro that would
update the validation.
 
A

Anne Troy

I'm not sure why you think you need a macro to do this. Using the same
features as this tutorial, you should be able to get your lookup to come
over:
http://www.officearticles.com/tutorials/order_form_or_invoice_form_in_microsoft_excel.htm
This describes VLOOKUP using a table (in case the tutorial is a bit more
information than you need):
http://www.officearticles.com/excel/vlookup_formulas_in_microsoft_excel.htm
But...maybe there's something I didn't understand. I've done concatenation
with vlookup, too. You just need to create one record in your lookup table
for every possible scenario, and then have a field that concatenates them.
And your vlookup might look like =vlookup(A1&B1,mytable,3,false)

************
Anne Troy
www.OfficeArticles.com
 
W

Warderbrad

the problem is not the lookup funtion, it is supplying the data for th
list in the Data Validation. Since the days do not have activities a
the same times I cannot use one list of values for everything. In th
example if a person wanted to attend on Sunday the drop down list woul
have to have the options of 5-7 or 9-11, but if they chose Monday i
would need to have the option of 4-6. It is putting those values int
the data validation list that I am having problems with, not th
looking up of other values once the time and day are known
 
Top