This is the legacy 4D documentation web site. Documentations are progressively being moved to developer.4d.com |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D v20 R7
Description of formula editor
|
Operator | Use | Description |
:= Assignment | A:=B | Assigns the value B to A |
+ Concatenation | A+B | Returns AB |
* Repetition | A*N | Repeats the value of A N times |
[[ ]] Indexes | [[A]]N | Returns the Nth character of A |
"" Empty string | "" | Inserts a pair of quotation marks |
Operator | Use | Description |
:= Assignment | X:=Y | Assigns the value Y to X |
+ Addition | X+Y | Returns X plus Y |
- Subtraction | X-Y | Returns X minus Y |
* Multiplication | X*Y | Returns X multiplied by Y |
/ Division | X/Y | Returns X divided by Y |
\ Integer Division | X\Y | Returns the integer division of X by Y (X and Y must be integers) |
% Modulo | X%Y | Divides X by Y and returns the remainder |
^ Exponentiation | X^Y | Returns X to the power of Y |
Note: The modulo % operator returns significant values with numbers belonging to the long integer category (from -2^31 to +2^31 minus 1). To calculate the modulo of numbers outside of this interval, use the Mod command.
Operator | Use | Description |
:= Assignment | D1:=D2 | Assigns the value D2 to D1 |
+ Addition | D1+N | Returns D1 plus N days |
- Difference | D1-D2 or | Returns the number of days between D1 and D2 |
D1-N | Returns D1 minus N days | |
!//! Blank date | !00/00/00! | Inserts a blank date |
Operator | Use | Description |
:= Assignment | H1:=H2 | Assigns the value H2 to H1 |
+ Addition | H1+H2 or | Returns H1 plus H2 |
H1+N | Returns H1 plus N seconds, expressed in seconds elapsed since midnight | |
- Subtraction | H1-H2 or | Returns H1 minus H2 |
H1-N | Returns H1 minus N seconds, expressed in seconds elapsed since midnight | |
* Multiplication | H1*N | Returns H1 multiplied by N, expressed in seconds elapsed since midnight |
/ Division | H1/N | Returns H1 divided by N, expressed in seconds elapsed since midnight |
\ Integer Division | H1\N | Returns the integer division of H1 by N, expressed in seconds elapsed since midnight |
% Modulo | H1%N | Divides H1 by N and returns the remainder |
?::? Blank hour | ?00:00:00? | Inserts a blank hour |
Operator | Use | Description |
= Equal | Z1=Z2 | Returns True if Z1 equals Z2 |
# Not equal | Z1#Z2 | Returns True if Z1 does not equal Z2 |
> Greater than | Z1>D | Returns True if Z1 is greater than Z2 |
>= Greater than or equal to | Z1>=Z2 | Returns True if Z1 is greater than or equal to Z2 |
< Less than | Z1<Z2 | Returns True if Z1 is less than Z2 |
<= Less than or equal to | Z1<=Z2 | Returns True if Z1 is less than or equal to Z2 |
Operator | Use | Description |
& AND | B1 & B2 | Returns True if B1 is True and B2 is True |
| OR | B1 | B2 | Returns True if B1 is True or B2 is True |
Product: 4D
Theme: Formula editor
4D Design Reference ( 4D v20 R7)