Reading Properties from Closed Files (Office and PDF)

Joined
Nov 19, 2017
Messages
2
Reaction score
0
A similar problem was posted some time ago (now in archive) relating to Excel 2003 but did not receive a reply.

I have exactly the same problem with Excel 2013 (32 bit) running on Windows 10 (64 bit) and I am hoping someone can help this time.

I am trying to read the propereties of closed files. I have downloaded the modDocumentProperties.bas file from Chip Pearson's site (http://www.cpearson.com/excel/DocProp.aspx) and imported it to my trial project. I have selected the DSO OLE Document Properties Reader 2.1 reference and installed the DSOFile DLL. The DSOFile demo works as expected on both Office files and pdf files.
Calling the function directly from the worksheet, loaded with the filename(including the path), the property name and set (built in, custom, both) but it always returns #NAME?
Calling the function from a macro gives the result shown in the screenshot attached.

I have to confess to being completely out of my depth and consiquently am not sure what questions to ask. I have whiled away a few happy hours (not) searching the web but cannot find enough to get to a point where trial and error works. I suspect the answer is simple and I am a right dumbo for not knowing it but for the life of me I cannot find an answer.

Can anybody help please?
 

Attachments

  • !Excel Object Properties 1.webp
    !Excel Object Properties 1.webp
    40.9 KB · Views: 203
I am not sure what my expectations should be as I am a newcomer to this forum but I am sure I should have had a response by now; is my query on the too hard heap or is it too stupid to warrant a reply!!?

I have been trying alternatives and now have too Excel workbooks containing identical code. It works in one workbook but the other gives the error shown in the previous download so I suspect it is an issue with the environment in which the code is running.

There are other modules in each workbook but I cannot see how they affect the error.

If there is anybody sufficiently interested in helping a quick response would be appreciated.
 
Back
Top