ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Reset Validation lists to display 1st value in list (https://www.excelbanter.com/excel-programming/385199-reset-validation-lists-display-1st-value-list.html)

Matt.Russett

Reset Validation lists to display 1st value in list
 
I have a large amount of validation lists that are updated with a
macro. However when I update the source of the list the value that is
currently selected in the list stays the same. Is there some code I
could add so my macro will not only update my source data but also
reset each validation list to display the top value?


Tom Ogilvy

Reset Validation lists to display 1st value in list
 
The validation list only works on what is manually entered. Values already
in the cell are not affected.

activecell.Value = Range("List")(1).Value

would put the first item in the named range "List" as the value of the cell.

--
Regards,
Tom Ogilvy


"Matt.Russett" wrote:

I have a large amount of validation lists that are updated with a
macro. However when I update the source of the list the value that is
currently selected in the list stays the same. Is there some code I
could add so my macro will not only update my source data but also
reset each validation list to display the top value?




All times are GMT +1. The time now is 12:21 PM.

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