Data>Validation>List .. How do I calculate the last ro

jhweaver

New Member
Joined
Jan 29, 2005
Messages
2
I have a a cell that only allows an input from a pre-defined list using the Validation option where 'Allow' = List and 'Source' = D2:D11.

However, occassionally I need to add (or delete) options from the list in column D so the range will change, eg. D2:D14.

How can I put that into the 'Source' field so that it will automatically calculate the last row of culmn D? Or is that beyond the capabilities of Validation? If so, can anyone recommend any other solutions?
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Re: Data>Validation>List .. How do I calculate the las

Welcome to the board! :)

jhweaver said:
I have a a cell that only allows an input from a pre-defined list using the Validation option where 'Allow' = List and 'Source' = D2:D11.

However, occassionally I need to add (or delete) options from the list in column D so the range will change, eg. D2:D14.

How can I put that into the 'Source' field so that it will automatically calculate the last row of culmn D? Or is that beyond the capabilities of Validation? If so, can anyone recommend any other solutions?

Define the range in D as a dynamic range which will automatically adjust, then use that defined name in data valdiation.

Go to Insert > Name > Define. In the box at the top put your dynamic name (i.e. myList). In the Refers to box at the bottom put this:

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

Click Add. Then OK.

Then in Data validation, for List put =myList
 
Upvote 0

Forum statistics

Threads
1,203,506
Messages
6,055,806
Members
444,825
Latest member
aggerdanny

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