Be sure to use the library name (Scripting) in front of the component name, when declaring objects, because some of the object names also occur in other libraries (for example, the Files collection is a member of the Outlook library as well as the Scripting library). To pick up file names from a folder, and store them in a table for purposes of comparison, you need to use several components of the Scripting Runtime Library. This can be done by using the FileSystemObject (part of the Scripting Runtime library) to iterate through the scanned files in the folder and put their names into an Access table, and then creating a query with the Find Unmatched Query Wizard to compare the file names in the folder with the entries in the table. He wrote to ask if I could suggest a method for comparing file names stored in an Access table to actual files stored in a folder on the hard disk, to see if any files have not been recorded in a table. Thanks to AW reader, Keith Hungate, for suggesting the topic of this article. How to compare actual files in a folder with files names in a table.
0 Comments
Leave a Reply. |