The CreatorCon Call for Content is officially open! Get started here.

Adding more variables to description field in Record Producer

Mr_ Thornquist
Tera Contributor

Good morning,

First post in the Community, so bear with me for being a rookie.

I've tried searching for my answer and got some steps further with adding more variables to one field in Record Procuders, but I have a some other challenges that I hope you can help me with.

I have a task to publish a public Service Portal, which means I can't rely on any lookup for mapping fields. This means that all my variables needs to be in text and map most of them to the 'Description' field. 

So, this is my current test script for mapping more than one variable to description.

current.description = producer.description_1 + producer.description_2;

The question for 'variable description_1' is 'Name' and question for variable 'description_2' is 'Name2'

Assuming I write 'test1' in variable 'description_1 and 'test2' in 'description_2'

The text in description field would be 'test1test2'. A text without breaks or any description for the variables. 

What I would like it to do is showing the question of the variable, colon, space, then the input from the variable, break, new variable, etc.

Example:

Name: test1
Name2: test2

Is this possible?

1 ACCEPTED SOLUTION

sachin_namjoshi
Kilo Patron
Kilo Patron

Yes, use below in your record producer script

 

current.description = "Name " + ":" + producer.description_1 + "\n"+  "Name2 " + ":" + producer.description_2;

 

Regards,

Sachin

View solution in original post

2 REPLIES 2

sachin_namjoshi
Kilo Patron
Kilo Patron

Yes, use below in your record producer script

 

current.description = "Name " + ":" + producer.description_1 + "\n"+  "Name2 " + ":" + producer.description_2;

 

Regards,

Sachin

I tried this script but it keeps showing up with the question and "undefined" at the end.