I have a level of experience in Excel VBA, but have never written an Outlook macro -- and hoped to never need to. But now I do.
We frequently send emails to customers with proposals attached, which are a collection of various docs -- a Word document, some spreadsheets, etc. Those docs are all maintained in a CM system (we use Perforce.) What I would like to do is this: When documents are attached, retrieve the path and filename for each. Then query Perforce to get the unique changelist number associated the version of each document (Perforce has a COM interface, I can do that), and list the attachments and their changelist numbers at the bottom of the email; e.g,
Proposal - Widget.doc 22517
Price - Widget.xls 22538
Compliance Matrix - Widget SOW.xls 22501
Then I can delete the documents from the sent mail (attachments redundant), and know what versions of what docs were sent in each email.
In the Send event, I can get filenames but not paths (unless they're linked docs, but they're not), and I need the complete path to query Perforce. There's some kind of an Attachment event, but no file properties available.
Any help appreciated. Will trade for exotic Excel formulas or VBA ...