|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Outlook VBA rule to search email attachements and move the emails into a folder
I would like to ask you if you could help me with the following. I want a rule in my Outlook to search the email's attachement for a specific word/words and in case it finds the word/words, it will move the email to a specific folder. As far as I know this is possible only using the VBA because the basic rule settings don't allow one to search the attachements. I'm not sure if it helps but the attachements I want to search are all PDFs. Thank you very much in advance.
|
#2
|
||||
|
||||
It is the reference to PDF file formats that has frightened off correspondents. PDF is not an Office format, so programming Office products to search PDF is difficult and will be affected by how the PDF files were created and what software you have.
In practice it requires a PDF compatible product that is programmable from VBA. Essentially that means you will need Adobe Acrobat and not merely Adobe Reader. If you had Word 2013, that offers another avenue as that can open PDF format, but your post does not acknowledge the presence of either. If you have Acrobat then the code at http://www.myengineeringworld.net/20...rough-vba.html should help with the search and that (while aimed at Excel) should be adaptable to Outlook. If you have Acrobat report back and we'll come up with a function that will work from a rule.
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
#3
|
|||
|
|||
thank you very much for your response. I'm sorry I forgot to mention that I have Office 2010. HOWEVER! When I open my Outlook, and type a word into the search box, here:
the Outlook search engine searches also the PDF attachements of all the emails. I know it because the other day I searched for a number that appears only in one PDF attachement and it did give me the result so I think that there is already some kind of PDF search engine already implemented in Outlook 2010, otherwise, how come it did search the PDF attachement and it did find what I needed? However, the problem is that no rule can be set to search the attachements. As for the Adobe Acrobat, I don't have it. I hope this helps and you will be able to give me an advice. Thank you very much. |
#4
|
||||
|
||||
As far as I can determine you cannot use Outlook search to search a message in this manner from VBA.
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
#5
|
|||
|
|||
so, there is no other way to do what I need to do?
|
#6
|
||||
|
||||
None that I am aware of - without Acrobat.
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
#7
|
|||
|
|||
And if the attachments were txt or doc formats, would it be possible?
|
Tags |
attachments, rule, vba |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Want to set up a rule to move sent emails | mylan | Outlook | 2 | 07-08-2014 05:10 AM |
Setting up a rule to move emails from inbox to Archive, or AutoArchive, etc | EatVegetables | Outlook | 0 | 03-18-2014 05:21 AM |
Outlook VBA to move selected email to a public folder | aaroncrt | Outlook | 2 | 10-21-2013 05:11 PM |
Rule to move sent messages to a specific folder | LouisOscar | Outlook | 1 | 08-17-2011 05:42 AM |
User cannot move email messages within Outlook Inbox folder and sub-folders. | Darsss | Outlook | 5 | 06-06-2011 11:37 PM |