ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   unique data validation drop down (https://www.excelbanter.com/excel-programming/377472-unique-data-validation-drop-down.html)

Nigel[_27_]

unique data validation drop down
 
so i have data validation from a range derived from variables as seen
below....

With Selection.Validation
.Delete
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop,
Operator:= _
xlBetween, Formula1:="=A7:A" &
Range("EndOfProducts").Offset(-1, 0).Row
.IgnoreBlank = True
.InCellDropdown = True
.InputTitle = ""
.ErrorTitle = ""
.InputMessage = ""
.ErrorMessage = ""
.ShowInput = True
.ShowError = False

so you can see that the range of my validation data is populated by
variables...which is working great...

the problem is...i need to edit it so that my drop down only shows
unique items, and omits any blank cells....

is this possible?


[email protected]

unique data validation drop down
 
Hi
Try Google this newsgroup with your question. Skip blanks is a
Validation option, so there should be a method for it. There is no
"unique Items" option in validation.
regards
Paul

Nigel wrote:

so i have data validation from a range derived from variables as seen
below....

With Selection.Validation
.Delete
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop,
Operator:= _
xlBetween, Formula1:="=A7:A" &
Range("EndOfProducts").Offset(-1, 0).Row
.IgnoreBlank = True
.InCellDropdown = True
.InputTitle = ""
.ErrorTitle = ""
.InputMessage = ""
.ErrorMessage = ""
.ShowInput = True
.ShowError = False

so you can see that the range of my validation data is populated by
variables...which is working great...

the problem is...i need to edit it so that my drop down only shows
unique items, and omits any blank cells....

is this possible?



Nigel[_27_]

unique data validation drop down
 
the ignore blanks doesn't ignore displaying them in the drop down, it
ignores them when validating the cell...

there should be a way with VBA to accomplish both things....
it seems weird that it wouldn't be built in....what use is a drop down
if it displaying duplicates?



All times are GMT +1. The time now is 10:30 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com