AnsweredAssumed Answered

HTML Links to Attachments Not Working

Question asked by andreapasutti on May 8, 2018
Latest reply on May 15, 2018 by andreapasutti

UPDATED

 

I am using a Build String action to create links to attachments to be used in a task form. I am basically following the steps I asked in this post way back when. However, when I follow the same steps in Nintex 2016, the workflow throws in a jumble of junk to the end of the hyperlink and it doesn't work. I am using the Rich Text action in the flexi task form instead of the multi-line text field (although that doesn't work, either). The process in order:

  1. User fills out form, attaches at least one attachment.
  2. Workflow gets the attachments from the form.
  3. Workflow loops through collection and creates URL to attachments.
  4. Workflow adds URL as a field in workflow task form so approver can view the attachments from the task form and not from the email notification.

My workflow:

 

The rich text field in my flexi task form:

 

I thought perhaps trying to create multiple links was the problem, but it still doesn't work with just one attachment. The hyperlinks I generated from the form attachments work. When I send myself an email, this is what I get:

This URL format doesn't work in the rich text field, either. When I use the links I create (red framed box in workflow screenshot), the workflow throws in a bunch of garbage at the end of the URL and it doesn't work:

 

 

This %3C and %3E are the brackets surrounding the HTML and the word "Attachments":

 

UPDATE

I played around with a few things.

1) using a regular expression to remove the characters (red box, previous screenshot)

2) connecting a field in the task form to the variable that holds the links

3) connecting a field on the task form to the field on the list after I had updated the item with the attachments variable

 

This works when there is just one attachment or on the very last attachment in the collection.

 

This is how I want it to look, but Attachment 1 and Attachment 2 still have the garbage at the end of the URL. Attachment 3 works just fine (and so does a single attachment).

 

The garbage gets thrown in at the end after the last build string action:

 

I'm not sure why this doesn't work. I've tried replacing the characters as "</attachment><attachment> and as "%3C/Attachment%3E%3CAttachment%3E" and no luck. Replacing the text only works on the last value in the variable. I tried it with a collection also.

 

a) Why is the workflow throwing in this garbage when I create my itemAttachments_multi variable to hold them all?

b) Why doesn't replacing the text with a regular expression work on all the data in the variable?

Outcomes