Remove all attachments except pdf and rtf
Question / Problem
How can I remove all attachments except for specific file extensions with an Exchange Server Toolbox rule?
Answer / Solution
In order to exclude specific file types from the "Delete Attachments" action you can add the following Regex expression to the action:
(?!.*\.(pdf|rtf)$).*\..*$
With this expression only PDF and RTF files would not be deleted.
You can switch the "pdf" and the "rtf" with any file type you want to exclude.
To add more types (for example docx) simply add a |docx.
To only exclude a single extension you can remove everything from the brackets but one file type.