Using drop down list to get information about the selected

Powerdog

Board Regular
Joined
Oct 6, 2004
Messages
50
I'm trying to learn how to use a drop down list (B3 on sheet2) to get that person's information (hours and rate) from (E3 and G3) sheet1 to show up at E3 and G3 on sheet2 with that person's name in the list box.
Column A on sheet1 is "Defined" as nursesname.
I got some great help yesterday... but I still can't get a grip on how it's done. I keep getting errors...
I created this smaller example so I could understand easier how to link it all together.
I really do appreciate the patience and help.
Book1.xls
ABCDE
1NursesRateHours
2
3Barbara1033
4Dawn1542
5James3215
6Shelly951
Sheet1
Book1.xls
ABCDEFG
1
2NurseRateHours
3
Sheet2
 
Re: Using drop down list to get information about the select

Aladin and Yogi chime in on Dynamic Named Ranges here.

Smitty
 
Upvote 0

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
GO ME! *ahem* I mean, I got it (hey, I've never tried this before, I'm happy it worked :-D )

This worked for me:
Go to Insert\Name\Define and select the 'data' range from the list.

In the 'Refers to:' section, enter this:

=OFFSET(Sheet1!$A$1,0,0,COUNTA(Sheet1!$A:$A),COUNTA(Sheet1!$1:$1))

This should set the range as A1 being the top left cell of the range, and then it counts down column A to get the number of rows used, and counts across row 1 to get the number of columns.

You won't be able to select the range from the name box as with a normal named range, but you can test if it worked by pressing Ctrl+G and entering 'data' in the reference box and pressing enter. It should select the range. And if you add anything to the table, it should catch those as well.

You could also do this for the Nurses range if you wanted, instead of the entire column or whatever you did. For that, you would use:
=OFFSET(Sheet1!$A$1,0,0,COUNTA(Sheet1!$A:$A),1)

This should then also work with your VLOOKUP formulas on Sheet2 and the named range you use for data validation without having to worry about new information to the list being included :)
 
Upvote 0

Forum statistics

Threads
1,222,703
Messages
6,167,743
Members
452,135
Latest member
Lugen

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top