Table of Contents

Search

  1. Preface
  2. Part 1: Using Process Developer
  3. Part 2: Creating and Modifying Processes
  4. Part 3: Functions, Events, Errors, and Correlation
  5. Part 4: Testing and Deployment
  6. Part 5: Process Central and Process Server (On-Premises)

Process Developer

Process Developer

Attachment Custom Function Examples

Attachment Custom Function Examples

The following examples of using custom functions show the manipulation of attachments in copy operations of assign activities. For a detailed description of each function, see Custom Functions for Manipulating Attachments.
Example 1:
Copies the first attachment from the
incomingMessage
variable to the
resultMessage
variable. The return value of
copyAttachment
is copied to the unused
tempVar
.
<copy> <from>abx:copyAttachment ("incomingMessage",1,"resultMessage") </from> <to variable="tempVar"/> </copy>
Example 2:
Removes the (N - 1) attachment; that is, removes the second-to-last attachment from the
resultMessage
variable, where N is the count of attachments on
resultMessage
.The return value of
removeAttachment
is copied to the unused
tempVar
.
<copy> <from>abx:removeAttachment("resultMessage", abx:getAttachmentCount("resultMessage") - 1 ) </from> <to variable="tempVar"/> </copy>
E
xample 3:
Copies the value of the
Content-Transfer-Encoding
property of the first attachment to the
resultMessage
variable.
<copy> <from>abx:getAttachmentProperty("resultMessage" , 1 , "Content-Transfer-Encoding") </from> <to part="propResult" variable="resultMessage"/> </copy>

0 COMMENTS

We’d like to hear from you!