You are viewing limited content. For full access, please sign in.

Question

Question

Workflow: Unable to send multi-line token to Web Request & possible bug

asked on April 24 Show version history

This is with Laserfiche Cloud. 

I have a multi-line text area field in a Business Process form called Description. If I enter a description into that field that doesn't have any line breaks, it works great. If I enter a description with line breaks, the web request fails. I tried applying an index on line breaks, but that doesn't work. If I enter "\n", the web request will accept it, but I can't figure out how to replace invisible line breaks with "\n". Is there a way to do that? I also tried using JSON formatting on the token, but that ran into issues as well as it only escaped what was inside each line, and not the line breaks themselves.

An alternative I've tried is to make Description a multi-valued token. I then create a Full Description token which iterates through each line of Description and adds "\n", keeping it on a single line. I ran into a bug with this (see attached pictures):

1) I click on the Description token: Apply Index > The value at Index > For Each Value - Iteration

2) Click OK.

3) Open the Description token. It now has: Apply Index > All values separated by > For Each Value - Iteration

No matter what I do, it will not allow me to keep "The value at Index" selected. So when I run my workflow, I only ever get the first value multiple times (however many values there are in the Description token). Regardless, even if this worked, this isn't an elegant solution to the initial problem so I'm hoping someone has a better idea than this.

To summarize, I want to convert this (not web request friendly):

TEST1
TEST2
TEST3

To this (web request friendly, using workflow):

TEST1\nTEST2\nTEST3

Thanks in advance.

Screenshot 2025-04-24 140116.png
Screenshot 2025-04-24 140101.png
0 0

Replies

replied on April 24

After I posted this I continued trying a few different things, and I came by a combination that worked. Keep Description as a multi-valued token. Create a Full Description token that is equal to Description >  Apply Index > All values separated by > "\n". I tried this before but without adding a separate Full Description token (just modifying the Description token on the web request).

1 0
You are not allowed to follow up in this post.

Sign in to reply to this post.