Skip to main content

Formating formula syntax

  • January 11, 2023
  • 3 replies
  • 244 views

Guillermo Puls
Wallflower
Forum|alt.badge.img+1

Hi Pigment team:

I’m trying to format the formulas so I can make them easier to read.

For instance, I have a formula that is an addition of 4 items and goes on for 5 lines (difficult to read), I’m looking to structure the formula in 4 lines (easier to digest):

= Item 1 +

Item 2 +

Item 3 +

Item 4

 

Is this something we can do?

 

Thanks in advance :D

3 replies

Stef
Employee
Forum|alt.badge.img+12
  • Employee
  • January 11, 2023

Hi @Guillermo Puls ,

You can use SHIFT + ENTER to add new (blank) lines in your formula. 

Something like this: 

 

You can also add comments with “//” (for single line) and “/*” and “*/” for multiple lines. Hope this helps. 


francois
Employee
Forum|alt.badge.img+13
  • Employee
  • January 11, 2023

Hi,

For more advice on formula formatting, here’s an article I’ve written that has some advice on what you can do.

In that case, I’d recommend having the + at the start of the line, as I find it easier to see at a glance.


Guillermo Puls
Wallflower
Forum|alt.badge.img+1
  • Author
  • Wallflower
  • January 11, 2023

Thanks Stef and François,

I tried command /Control + Enter and wasn’t working, now that article sits in my favourites.

Thanks again!