How to add line breaks in a single string Variable

0
I have created a Document with a single String variable. This variable has some text. Text in Document is like: ......... some english words....... a)......... some more words  a.1)..... some more words  a.2)....some more words b).....some words I give this Document data at run time. I have used a text area and have written the text in above format only (using enter button for new line), but when I download the Document, I do not get this format. Am getting everything like a paragraph.  Is there any way in which I can get the data in above format. PLease let me know. Modeler version hat I use here is 5.19.0
asked
6 answers
6

For this you have to use Rich text widget

 

https://marketplace.mendix.com/link/component/74889

answered
4

You can build a string variable in your microflow with line breaks like this:

$ValidationMessage+'
- First finalize handling assignment.'

Start with a quote on the first line and write the string on the second line.

See: http://www.nolanramsey.com/blog/2015/3/12/display-line-breaks-in-your-mendix-strings

answered
3

As Jeffrey said, you should use CKEditor to edit your string variable.  Then, in the document template, for that string attribute, set Render XHTML to true.

answered
2

Hi Manasa,

 

Perhaps you can take a look at the CKEditor widget version 2.2, this version should work with your modeler version. 

If you don't want to work with a widget, you have to run the commit through a Microflow and add the linebreaks there.

 

Good luck, search this forum can also help you find answers, as I believe this is asked before.

 

Kind regards,

Jeffrey

answered
2

Did you try adding line breaks

Try "\r\n" or maybe "<br / >"

 

EDIT: Haven't tested it

answered
0

<br/> worked for me!

answered