Virtual Agent Dynamic choise input - new line character

js20
Mega Guru

in Virtual Agent I am creating dynamic choise input following:

[{"value":"id of case","label": " some label\nnew line"}]. 

But new line character (\n) is trimed from menu. 

Is there way how to add new lines to have more user friendly menu?

 

Thank you

5 REPLIES 5

Sujatha V M
Kilo Patron
Kilo Patron

@js20  In dynamic choice input scripting section, did you try to add as below?

 

 

var options = [];
options.push({ 'value': 'option_1', 'label': "Option 1", 'render_style': 'data' });
options.push({ 'value': 'option_2', 'label': "Option 2", 'render_style': 'data' });
return options;

 

 

SujathaVM_0-1715596402328.png

 Please mark this as helpful and accept it as a solution if this resolves your query.

Thanks,

Sujatha V.M.

 

Please mark this as helpful and accept it as a solution if this resolves your query.
Sujatha V.M.

I dont see new line in your example . I want to hame menu looking like this:
Inc Number: 12345

Status: New

-----------------------------

Inc Number: 67788

Status: New

I assumed you are trying to get those options in new lines. The above message is much clear on what's your expectation. Let me give it a try. 

 

Please mark this as helpful and accept it as a solution if this resolves your query.

Thanks,

Sujatha V.M.

Please mark this as helpful and accept it as a solution if this resolves your query.
Sujatha V.M.

sorry for confusion , same menu item but 2 lines in each.