You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+68-3Lines changed: 68 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -86,8 +86,11 @@ Using XTL provides the following benefits:
86
86
Native Types:
87
87
- String Constants (Alpha numeric text inside quotes)
88
88
- Integers (Digit expression)
89
+
- Doubles (Digits are separated by '.', a 'd' is appended to separate from decimals. E.g: 1.4d)
90
+
- Decimals (Digits are separated by '.', a 'm' is appended to separate from doubles. E.g: 1.4m)
89
91
- Booleans (true or false)
90
92
- Functions (Identifiers without quotes followed by parenthesis with parameters)
93
+
- Dictionaries (JS style objects, such as { propertyName: value }. Value can be a constant or another expression.
91
94
92
95
In addition, null is also a reserved keyword.
93
96
@@ -145,11 +148,43 @@ Example:
145
148
IsEqual ( Value ( "gendercode" ), 1 )
146
149
```
147
150
151
+
### IsLess
152
+
Checks if first parameter is less than the second. If yes, true is returned, otherwise false.
153
+
154
+
Example:
155
+
```
156
+
IsLess ( 1, 2 )
157
+
```
158
+
159
+
### IsLessEqual
160
+
Checks if first parameter is less or equal than the second. If yes, true is returned, otherwise false.
161
+
162
+
Example:
163
+
```
164
+
IsLessEqual ( 1, 2 )
165
+
```
166
+
167
+
### IsGreater
168
+
Checks if first parameter is greater than the second. If yes, true is returned, otherwise false.
169
+
170
+
Example:
171
+
```
172
+
IsGreater ( 1, 2 )
173
+
```
174
+
175
+
### IsGreaterEqual
176
+
Checks if first parameter is greater or equal than the second. If yes, true is returned, otherwise false.
177
+
178
+
Example:
179
+
```
180
+
IsGreaterEqual ( 1, 2 )
181
+
```
182
+
148
183
### Value
149
184
Returns the object value of the given property. If it is used as top level function, the matching string representation is returned.
150
185
The text function which was present in early releases was replaced by this, as the Value function hosts both the string representation and the actual value now.
151
186
You can jump to entities that are connected by a lookup by concatenating field names with a '.' as separator.
152
-
Default base entity for all operations is the primary entity. You can override this behaviour by passing an entity object as second parameter.
187
+
Default base entity for all operations is the primary entity. You can override this behaviour by passing an entity object as config parameter named `explicitTarget`, like so: `Value("regardingobjectid.firstname", PrimaryRecord())`.
Returns a table of records with specified columns and record url if wanted.
213
248
First parameter is a list of records, for displaying inside the table. Consider retrieving them using the Fetch function.
214
-
Second is the name of the sub entity, third whether to include URL or not.
249
+
Second is the name of the sub entity.
215
250
Third is an array expression containing the columns to retrieve, which will be added in the same order.
216
251
By default the columns are named like the display names of their respective CRM columns. If you want to override that, append a colon and the text you want to use, such as "subject:Overridden Subject Label".
217
252
253
+
If you wish to append the record url as last column, pass a configuration object as last parameter as follows: `{ addRecordUrl: true }`.
254
+
There is also the possibility to configure table, header and row styling. Pass a style property inside your configuration parameter, as follows: `{ tableStyle: "border:1px solid green;", headerStyle: "border:1px solid orange;", dataStyle: "border:1px solid red;"}`.
255
+
Only pass one configuration object, it can contain information on addRecordUrl as well as on table styling.
256
+
218
257
Below you can find an example, which executes on e-mail creation and searches for tasks associated to the mails regarding contact.
219
258
It will then print the task subject and description, including an url, into the mail.
Info: This is needed when wanting to concatenate multiple texts using concat or join, since passing "\n" as .NET line break string is interpreted as plain string.
291
330
331
+
### DateTimeNow
332
+
Gets the current local time.
333
+
334
+
Example:
335
+
```
336
+
DateTimeNow()
337
+
```
338
+
339
+
### DateTimeUtcNow
340
+
Gets the current UTC time.
341
+
342
+
Example:
343
+
```
344
+
DateTimeUtcNow()
345
+
```
346
+
347
+
### DateToString
348
+
Prints the date that is passed as first parameter. A custom format can be appended using a configuration object with format key.
0 commit comments