Solved

How to separate list of values by making each start on a new line

  • 5 September 2019
  • 1 reply
  • 4 views

Hello,

 

I am trying to setup a workflow which gets a list of users in a role then that reference goes through a list of projects for each user and the idea is that in an email notification these users will get a list of all their projects so they know which updates they need to provide updates for.

I found that with the join function I was able to add a ; between each item in the list but I was wondering if there is a way to have each value returned from a create refernce step start on a new line.

The first step in the workflow gets all the users in a role I made, then it loops through those users and for each user it fills a reference with all projects that user is a part of.

Thus if a user has 5 projects I'd like the projects to be listed out in an email like:

Project 1

Project 2

Project 3

 

Instead of what I currently have which is: Project 1; Project 2; Project 3.

Is there a way to achiveve this with a K2 function?


Thanks,

Nick Shouse


15074i8EFED5DD8090D483.jpg
12321i6DC023E552DC4EF1.jpg
17137iF81E0D3E69801D6C.jpg
16964i9BBC08709AA2CFF5.jpg

icon

Best answer by SamuelT1 6 September 2019, 21:34

View original

1 reply

Hey NShouse, 


 


Have you tried using <br/> to create new lines in your expression. I did a quick test with this using a workflow variable along with a loop step to itterate through the list. Once I sent the final email with just the data from the variable I saw data that looked like: 


Project 1


Project 2 


Project 3


 


Depending on your setup, you may be able to use the replace funtion to replace the semicolons with the <br/> tag or you might be able to use the join funtion to insert the tag. 


 


K2 will not accept any liability for any issues arising form actions taken in repect of the information provided by any forum member. 


 


Thanks, 


Sam

Reply