Does anyone know of a way I can get VBA to pick up the descriptions I have entered manually in my report properties through the database window?
I wish to create a combo field in a dialog box, which will enable the user to view a sorted list of reports and select one to open and/or print. I have a couple of hundred reports whose descriptions have been carefully created for sorting and clarification purposes. I need to loop through the list of reports and store in an array the names and descriptions of any that are not hidden. This array will then be sorted for use in the combo list.
If I use the AllReports collection, I can access very little information without opening the reports; for example, I can get the name, but cannot check the Visible or Tag properties.
If I loop through AllReports and open each report in turn, I can access the Visible property and other properties such as Tag, but do not seem to be able to access the report description in any way. I also find that, even with Echo off, there is a lot of flicker as it opens, reads, then closes each report to build the list.
So far, my best solutions are to:
(a) Create a table with fields for the report name and description (this would allow me to create additional fields to assist selection, but would be very time-consuming, and require careful maintenance every time a report is added, modified or deleted); or
( Manually copy the Descriptions to the Tag fields, then loop through AllReports to open each report and put the name and Tag property into the array (which would also be time-consuming and require maintenance as for (a), as well as having the flicker problem).
Perhaps I am missing something – I have looked through the enormous list that is displayed when I click the More Controls button on the Toolbox, but nothing stands out as an obvious way of enabling the user to browse a list of reports.
I have searched back over a year of posts and don’t believe this question has already been raised, but apologise if it has been and I have just missed it. I’m sure there are brighter minds out there than mine, so hope someone can make sense of my question and point the way to a solution!
Thanks and regards