
Need Help!! Coding a drop down list
Use dropdowns from the forms toolbar or use Data=>Validation with the List
option
then define a dynamic range for your source data
Insert=>Name=>Define
Name: Employees
RefersTo: =Offset(Sheet2!$C$1,0,0,Countif(Sheet2!$C:$C,"<>"),1)
Then click the Add button
Now for your source data for the controls put in
=Employers
This should update automatically when you add and delete cells.
This doesn't work well with controls from the control toolbox toolbar.
Regards,
Tom Ogilvy
Quote:
> I am building a spreadsheet for office use. I have roughly 50 drop
> down lists on a spreadsheet (Sheet1) that are used for employees. The
> corresponding list (input range) of employees are in column "C" on
> sheet 2. Every time a new employee comes, or one leaves, I have to
> manually change the input range of all the drop down lists. What I
> want to do is have a command button on sheet 2 so when the user needs
> to add an employee, they can push the command button and an input box
> will pop up asking for the name. I then need the code to update all of
> the drop down boxes as well as column C, putting the name in ascending
> order (alphebetical). I would also need a command button to delete
> employees. I would include a sample of the spreadsheet but for
> employee confidentiality, I can't. If anyone knows how to accomplish
> something like this, your help would be greatly appreciated.(I realize
> this is somewhat of a database but Access was unavailable at the time
> this was created). Thanks