Legacy Dev Forum Posts

 View Only

Sign Up

  • 1.  Search email attachment

    Posted 06-05-2025 19:10

    John_Watson | 2020-03-06 03:14:31 UTC | #1

    Just looking to direct an email interaction to a particular queue if it includes .pdf in the file name. Trying to search the Email.Message.attachments , but it does not contain the filename.

    Any ideas how I am able to extract the attachment name?

    Thanks

    John


    anon28885283 | 2020-03-06 14:48:45 UTC | #2

    Email.Message.attachments is a collection of EmailAttachment objects.

    What you can do is loop through the collection and check their name property.

    Here's an example of getting the name property of the first attachment:

    Email.Message.attachments[0].name

    And here's an example on how to check if ".pdf" exists in the name of the first attachment:

    FindString(Lower(Email.Message.attachments[0].name), ".pdf") >= 0


    John_Watson | 2020-03-09 06:10:24 UTC | #3

    Great, thanks - will take a look.

    John


    system | 2020-04-09 06:21:53 UTC | #4

    This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.


    This post was migrated from the old Developer Forum.

    ref: 7284