Sundaram Sridharan Posted February 16, 2022 Share Posted February 16, 2022 I need to read the files in a windows folder and offer them as items in a drop down menu. so far I have import os myFolder = "\serverfolder" list = [] for file in os.listdir(myFolder): list.append(file) I now need to somehow assign this to a listbox document property so it will appear as pull down menu. I can trigger this script using a simple data function. But when I create a listbox (multi select) document property and try to assign this list to that property it doesn't change anything in the text area. However if I choose file-document properties, I see the above list assigned to the document property. Is there another way to do this Link to comment Share on other sites More sharing options...
David Boot-Olazabal Posted April 1, 2022 Share Posted April 1, 2022 Hi SidSri, Would you be able to share the .dxp file which has this in it Kind regards, David Link to comment Share on other sites More sharing options...
Sundaram Sridharan Posted April 1, 2022 Author Share Posted April 1, 2022 Sorry didn't get a chance before to post the solution I found. You need to turn the list into a data table first. And trigger the action using a data function that runs at load time so the dropdown list is ready for you. In the example I enclosed I am listing the contents of my "C:oracle" folder Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now