<div class="markdown">
<p dir="auto">On 1 Oct 2014, at 12:08, Jason Davies wrote:</p>
<blockquote>
<p dir="auto">[background]</p>
<p dir="auto">I thought this would be fairly straightforward but seem not to be able to get the logic right. This is partly because X-attachment-type doesn't work as I expected (I thought I could write 'docx' in there but that returns nothing).</p>
</blockquote>
<p dir="auto">You should be able to match on any header in a message, but it's tricky to match on a subset of a header if there is no specifier available for it by default.</p>
<blockquote>
<p dir="auto">[…]</p>
<p dir="auto">AT this point I have tried to think how to check what you could write as</p>
<p dir="auto">If attachment count is 1<br>
and attachment name is image001.png<br>
then exclude from smart mailbox</p>
<p dir="auto">But I can't translate that successfully into smart mailbox rules. Sometimes there are multiple word docs, for instance and there may be a signature graphic - or not.</p>
<p dir="auto">I'm currently trying it by having multiple smart mailboxes which is the only way I see to exclude things but that is also not turning out as I hoped...;)</p>
</blockquote>
<p dir="auto">I would probably need some concrete example to precisely understand what you are trying to do, but it's a good idea to create separate smart mailboxes to separate each matching issue.</p>
<p dir="auto">It is very tricky to match on attachments for various reasons. It's tricky to even count the attachments as done for <code>Attachments-Count</code>. One thing to note is that when you try to match on headers of attachments (or any other subpart of a message) then you need to use the “All Body Parts” toggle in the comparison popup. This ensures that MailMate looks beyond the headers of the root headers of each message. But this does not cover all use cases since it's very hard to combine conditions for a single subpart.</p>
<p dir="auto">-- <br>
Benny</p>
</div>