ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Programmatically query Excel drop-down list ? (https://www.excelbanter.com/excel-programming/363099-programmatically-query-excel-drop-down-list.html)

diglas1 via OfficeKB.com

Programmatically query Excel drop-down list ?
 
Can I programmatically query an Excel drop-down list and programmatically
update the drop-down cell ?
I am trying to populate one spreadsheet with data from another using an Excel
macro, but one column contains drop-down boxes. Can I query the drop-down
list from my controlling macro and populate the cell with one of the entries.

Thanks in anticipation.

--
Message posted via http://www.officekb.com

Tom Ogilvy

Programmatically query Excel drop-down list ?
 
Are you talking about data = Validation using the list option.


If so, do you know where the data is that is used to populate the list? If
so, just get a value from that. Data validation doesn't react to entries
made by code.

--
Regards,
Tom Ogilvy


"diglas1 via OfficeKB.com" wrote:

Can I programmatically query an Excel drop-down list and programmatically
update the drop-down cell ?
I am trying to populate one spreadsheet with data from another using an Excel
macro, but one column contains drop-down boxes. Can I query the drop-down
list from my controlling macro and populate the cell with one of the entries.

Thanks in anticipation.

--
Message posted via http://www.officekb.com


diglas1 via OfficeKB.com

Programmatically query Excel drop-down list ?
 
Tom,
Yes re Data == Validation.
Thanks for your response; unfortunately, when I select the drop-down "List"
cell, then Data from the toolbar, the Validation option is greyed out. I
know the workbook is unprotected as the formulae for all cells are visible,
so presume it's not a security issue.
Could the source for the drop-down list box be created and it's whereabouts
protected somehow in a macro ? (the macros for this spreadsheet are greyed
out, so must be protected.)
Thanks


Tom Ogilvy wrote:
Are you talking about data = Validation using the list option.

If so, do you know where the data is that is used to populate the list? If
so, just get a value from that. Data validation doesn't react to entries
made by code.

Can I programmatically query an Excel drop-down list and programmatically
update the drop-down cell ?

[quoted text clipped - 3 lines]

Thanks in anticipation.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200606/1


All times are GMT +1. The time now is 01:40 PM.

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