New Line or Enter within a string variable

Hi,

I am currently building a scenario that would read multiple values into a variable, which is sent to a field. Essentially, I want to CONCAT values into this one variable. That is the easy part. Once the scenario runs again, I want to get the value from the field (that I can get), and then add a new value into the array and write it back.

But when the new value is added, I want to simulate ENTER or NEWLINE.

Eg.
Value 1,
Value 2,

The above would be the final output. Currently mine looks like this when it is send back to a textbox:
Value 1,Value 2,

What is interesting, if I inspect the variable it looks correct (2 lines), but when I write it back to the field (textbox) it appears as one line.

I found the function newline and carriagereturn, but that does not seem to work.

1 Like

Hi @Laurens_Kruger

Sample variable:


Replace , with newline:

Output:

Best regards,

Msquare Automation
Gold Partner of Make
@Msquare_Automation

Thank you. I did something similar.

I inspected my output on the variable and the output is correct.

When I then push the value of the variable into a textbox field, it comes out as one long string vs the output of the variable. I wonder if something happens from variable to textbox field

1 Like

Hi @Laurens_Kruger

Every module have different properties to accept the text. Without knowing the module where you are feeding this data, it is uncertain to predict the solution. However, you can try using join() function as at most of the modules it works.

If this doesn’t resolve your problem, please share the screenhot of the module mappings and let us know which module you are using.

Best regards,

Msquare Automation
Gold Partner of Make
@Msquare_Automation