GetItemAttachments function

Applies to JungleDocs for Office 365.
For JungleDocs for SharePoint 2010-2019 tutorials, click here.

This article describes the formula syntax and usage of the GetItemAttachments function in JungleDocs for Office 365.


Description

Retrieves item attachments from a SharePoint list.

Syntax

GetItemAttachments()

Within the content control with the GetItemAttachments function, you can use additional content controls with the following functions:

AttachmentFileName

Returns the attachment's file name.

AttachmentUrl

Returns the attachment's URL address.

Image(attachmentUrl)

Displays the image attachment and has the following arguments:

  • AttachmentUrl   Required. The URL address of the attachment.

Hyperlink(attachmentUrl; attachmentFileName)

Displays the link to the item attachment and has the following arguments:

  • AttachmentUrl   Required. The URL address of the attachment.
  • AttachmentFileName   Required. The link title.

Remarks

  • The GetItemAttachments function works only within a repeated section.
  • Since only list items can contain attachments, and documents cannot, the function will not work with SharePoint libraries.

Example

To retrieve attachments in reports

1. Create a table with a repeated section.

2. Select the table and insert a plain text control. Then, open control properties and enter  GetItemAttachments() in the Title and Tag fields.

3. Select a table cell and insert a rich text control inside. Then, open control properties and enter  AttachmentFileName or AttachmentUrl in the Title and Tag fields.

To display image attachments

1. Create a table with a repeated section.

2. Select the table and insert a plain text control. Then, open control properties and enter GetItemAttachments() in the Title and Tag fields.

3. Insert a picture control in the table cell where you want the image to be displayed.

4. Open control properties and enter Image(AttachmentUrl) in the Title and Tag fields.

To retrieve attachment links

1. Create a table with a repeated section.

2. Select the table and insert a plain text control. Then, open control properties and enter   GetItemAttachments() in the Title and Tag fields.

3. Insert a rich text control in the table cell where you want the link to be displayed.

4. Open control properties and enter  Hyperlink(AttachmentUrl; AttachmentFileName) in the Title and Tag fields.

5. Add hyperlink formatting to the control (otherwise, the hyperlink will adopt a plain text format).

Example

Below you can see a part of a document template with a repeated section configured and the GetItemAttachments function applied already. All the different ways to retrieve attachments are illustrated, too.

And here's a result after executing a JungleDocs rule:

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us