Skip to main content

Is it possible to have the data that is in a collection be put into a text variable, preferably a multi-line text variable?

I have data saved in a collection that I need to be displayed in an email that the workflow sends. Placing the collection variable in the email does nothing (which I figured) but I haven’t been able to find any solution.

Is it possible to have the data that is in a collection be put into a text variable, preferably a multi-line text variable?

Yes, possible

 

Here is the basic logic to get you started.

  1. Are you able to use LOOPS to extract each item from the collection?
    Collection1 = =“one”, “two”, “three”, ”four”, “five”]
    tmpStr => extract item from collection
  2. Are you able to declare an empty string?
    Msg1 = “”
  3. Are you able to concatenate strings and variables?
    Msg1 = Msg1 + tmpStr + eolStr
    // Msg1 => “one <br>”
  4. Are you able to identify the EOL or line terminator?
    For Logs/Console is “\n”
    For HTML is “<br>” 
    eolStr = “<br>” //for HTML email

Then you should be able to create the following string Msg1.

one <br>
two <br>
three <br>
four <br>
five <br>

 


Hi @mstallings 

Did this post help answer your question? 


Reply