Hello! Is it possible to include "new line" c...

Hello! Is it possible to include โ€œnew lineโ€ characters to strings/text inside formulas? How would new lines (or carriage returns) be represented? Thank you! Edit: for example, I want to add a linebreak in a concatenate function. CHAR() doesnโ€™t seem to work.

1 27 9,873
27 REPLIES 27

I donโ€™t understand what youโ€™re trying to say here? Example?

I want to include a linebreak in a concatenate function, for instance

@Mobile_Tuberculosis hrmmm not sureโ€ฆ @Aleksi_Alkio

tony1
New Member

@Mobile_Tuberculosis Just put a line break in quotes:

โ€œthis is line one and this is line twoโ€

Thanks

@tony. I tried it before and it didnโ€™t work; I guess the function was put in when I wasnโ€™t looking. This is great. Thanks again!

I wanted to do this, and it worked putting a line break in. The only problem was, when I came to export that column out to a pdf template, the line breaks disappeared, and the words ran into each other in the pdf template.

When using the CONCATENATE expression, you can use it like thisโ€ฆ

CONCATENATE(โ€œThis is line oneโ€,"

โ€œ,โ€œThis is line twoโ€,โ€

",โ€œEnd ofโ€)

Will this work for virtual Longtext column? I have tried the same. but it doesnโ€™t work. please advise.

Thanks.
John

Please post a screenshot of the complete expression youโ€™re using.

This works well. Howeverโ€ฆ

Iโ€™m using a table in a template, with multiple field references in the right-hand column across many rows. Itโ€™d be nice to have some rows appear conditionally. Thus:

---------------
Yadayada<<if(Eval=โ€Yโ€,โ€
---------------
โ€œ&[Evalfield1]&โ€
---------------
โ€œ&[Evalfield2]&โ€
---------------
โ€œ&[Evalfield3]&โ€
---------------
โ€œ&[Evalfield4]&โ€
---------------
โ€œ&[Evalfield5]&โ€
---------------
โ€œ),โ€โ€)>>Yadayada
---------------

This method will not work in that case; the actual html of the table causes an error for each table row traversed by the line-broken literal:

(I canโ€™t post the text of the error here for the same reason)

It would be nice if that could all be escaped, but I wouldnโ€™t have any idea how to do that, much less do it and make the html still be effective in creating the table. ๐Ÿ˜•

CRLF is pretty simple, so I can see how that can work. Unfortunately it canโ€™t handle anything more complex (note that I tried tripple quotes to break the literal up; it didnโ€™t work with single quotes either).

It also canโ€™t handle comments in the template document (which is darned unfortunate, since documenting what the heck one is doing with complex conditionals in a template would be handy to have in the document itself using something one would hope would be totally meta, such as document comments), as someone has noted elsewhere. Here, the word โ€œLevelโ€ (a fieldname) has a comment attached to it:

Argh.

Maybe this?

CONCATENATE(
  "This is line oneโ€,
  "<BR/>โ€œ,
  "This is line two",
  "<BR/>",
  ...
)

That doesnโ€™t work with Doc templates. How can we insert line breaks in the template?

In the App, yes. It writes them on separate lines in the spreadsheet (within the same cell). But not in a pdf template in a workflowโ€ฆ it doesnโ€™t maintain the line breaks.

@Green_Gorilla Thatโ€™s true. It will work with the Email body, but not with the Doc template.

Possible to be able to implement something for this? Starting to see some future use cases for it.

Has anyone found a way to insert line breaks via code in Doc templates?

Like <<CONCATENATE("Hello, br attribute goes here, โ€œWorld!โ€)>>


The Virtual LongText Column name is โ€œxUserInfoโ€ to be printed like below

John Henry Joseph
QA/QC Manager, SHEQ Department, Bahrain
Raised on 11/6/2020 12:40:39

I want to show in Card typeโ€ฆ screenshot is below.

Please advise.
Thanks.

It would appear the card view cannot display LongText values.

You mean multiline in virtual column text field will serve the purpose?

That question makes no sense to me.

I think Steve is right as I just tried to do the same thing. I have a LongText field with CR/LF in it and Card View just ignores this and displays as a single line of text, wrapping as it sees fit.

Mike_T
New Member

Somewhat relatedโ€ฆI added a line break but my line spacing is way off. iโ€™m trying to build a dashboard and show a large number. Format rule is bold, green and bumped up to 1.2 font size. How do I space this out so itโ€™s legible?

3X_a_d_ad44a68042afa677fa1c324383bf09de205b87b2.png

Forgot to mention this is a Show Type column in a Detail Viewโ€ฆonly showing the one row.

I solved by using an extra line break for spacing.

Expression:

COUNT(filter(Monitoring,[Status]=โ€œActiveโ€))&"

โ€œ&โ€œActive Monitoringโ€&โ€

"&โ€œEventsโ€

Result:

CONCATENATE( [ColumnA],"

โ€œ,[ColumnB],โ€

",[ColumnC])

Im not sure if it works, but it has been marked as solution in other posts

En la expresiรณn CONCATENATE, no funciona nada de lo que habรฉis publicado aquรญ, yo lo escribo como habรฉis dicho:

CONCATENATE([CCAA/FSS] ,"

โ€œ,[AF INAP],โ€

",[HORAS])

y se me queda todo junto en una linea con un campo tipo "longtext", en una vista tipo "Card", llevo mรกs de 5 horas con este tema y si no se puede hacer, lo que se tiene que comentar es que es imposible y ya estรก.

 

 

On:

Card View
Virtual column type LonText

Neither CONCATENATE and & works for me.

 

What is the context around what you're trying to do? ie onboarding view, Show column, Display text??

Top Labels in this Space