First off, I'm not very good at python but I need help with the follow code. All I'm trying to do is generate an attachment match table by selecting pictures stored in sub folders. Please note that the snippet below is part of a larger script. When I run it, no errors are generated and everything works fine except for the match table (which gets created, but comes up empty every time). I'm using ArcGIS 10.5. and there is a field in the database table named "RadioCall" that has the same names as the pictures. The field is a 'string.'
# Description: Creates an attachment match table for all files by walking through a set of subfolders
rootFolder = "W:\InventoryPhotos"
for folder in os.walk(rootFolder):
arcpy.GenerateAttachmentMatchTable_management(Fleetdata, folder, Matchtable, "RadioCall", ".jpg", "RELATIVE")
Any help would be appreciated.