Skip to content

What is ApptiveScript ​

ApptiveScript is ApptiveGrid's expression language. An expression is a single calculation, lookup, or condition — it takes values, does something with them, and produces a result.

You've very likely already used ApptiveScript without noticing.

Every filter is already an expression ​

When you filter in a View — Status equals Open — ApptiveGrid writes exactly this behind the scenes:

fieldValue('<Status>').isEqualTo('Open')

The conditions from the filter dialog are functions of the language:

Condition in the interfaceFunction
equals · does not equalisEqualTo · isNotEqualTo
containscontains
is greater than · is less thangreaterThan · smallerThan
is empty · is not emptyisEmpty · isNotEmpty
includes any of · none of · all ofincludesAnyOf · includesNoneOf · includesAllOf
is before · is afterbefore · after
AND · ORlogicalAnd · logicalOr

The same goes for relative date values: today is today(), yesterday is today().subtractDays(1).

The dialog writes along with you

If you want to write an expression by hand, the fastest way to get started is to build it via the dialog first and then look at what comes out of it. The simple selection and the expression are two views of the same thing.

Where you can write your own expressions ​

ApptiveGrid offers a field for a custom expression in seven places:

PlacePurposeResult must be
Formula column in a GridCalculate values within an entrythe chosen result type
Conditional visibility of a block, Advanced sectionShow blocks depending on inputa boolean
Flow transition, Advanced logicContinue a branch only under certain conditionsa boolean
Text fields in Flow stepsInsert values into subject, body, URLtext
Filter, when the selection isn't enoughCombine multiple conditionsa boolean
Relative date values in filters"7 days ago" instead of a fixed datea date
Settings fields of type Expression in individual Flow stepsCalculate a value instead of entering itdepends on the step

The syntax is the same everywhere. What differs is only what an expression is allowed to start with — that depends on which values are actually available at that point. → Referencing values

What ApptiveScript is not ​

Not a programming language

There are no variables, loops, custom functions, or intermediate steps. An expression is a single line that produces a value. If you need multiple steps, a Flow is the right tool — or several formula columns building on each other.

Not the JavaScript step

The Flow step JavaScript is something different: it runs actual multi-line JavaScript, with variables and a return value. ApptiveScript is the small language for individual expressions in fields. → Actions

No access protection

A visibility rule decides what gets displayed — it doesn't protect any data. If you need to truly hide content, you need access restrictions.

When something isn't right ​

The most important thing first: a broken expression usually doesn't make any noise. It produces nothing, and what happens next depends on where it is:

PlaceBehavior for an expression that doesn't work out
FilterThe entry is considered not matching and disappears from the View
Conditional visibilityOn an error the block stays visible; on an empty result it's hidden
Text field in a FlowNothing is inserted — the text stays blank at that spot
FormulaThe column stays blank

Which leads to the most important debugging rule: a field that unexpectedly stays blank, or a block that always disappears, is the classic sign of a typo in the expression — not of a permissions problem.

A name that doesn't exist isn't an error, it's simply blank. formValues.get('age') returns nothing if the Key is actually called alter. Which is why you should never type Ids and Keys — always insert them. → Referencing values

Next ​

Was this page helpful?