I've been unable to add attachments with docx or xlxs extension, obtaining an error that states 'The given key was not present in the dictionary'. Converting the docx file to pdf made it work, although I don't see why there needs to be such restriction.
I've obtain the same error using the following:
featureLayer.attachments.add(oid,file_path',keywords='test')
managers.AttachmentManager(featureLayer).add(oid,file_path',keywords='test')
Is this a bug?
Thanks.
Javier
Hi,
Could you tell me the service name? Is it starting with a number rather than a letter?
Best regards,
Fred
Thanks for your reply Fred.
The service name is Prescribed_Fire_Grant_Application_MASTER_2023. I've used the same code successfully in the past, but I've started having issues after updating to the latest version of ArcGIS Pro.
I hope this helps.
Javier
Have you made sure you updated the required drivers for Microsoft stuff as described here?
R_
Still the same result. Note I'm running python on PyCharm which is pointing to ArcGIS Pro.
Thanks.
Javier