Skip to content

Commit f353f98

Browse files
authored
Merge pull request #196625 from microsoft-dustin/isint-template-function
New isInt() template expression function
2 parents 144371a + f07ae6f commit f353f98

File tree

1 file changed

+31
-1
lines changed

1 file changed

+31
-1
lines changed

articles/logic-apps/workflow-definition-language-functions-reference.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ To work with strings, you can use these string functions and also some [collecti
9898
| [formatNumber](../logic-apps/workflow-definition-language-functions-reference.md#formatNumber) | Return a number as a string based on the specified format |
9999
| [guid](../logic-apps/workflow-definition-language-functions-reference.md#guid) | Generate a globally unique identifier (GUID) as a string. |
100100
| [indexOf](../logic-apps/workflow-definition-language-functions-reference.md#indexof) | Return the starting position for a substring. |
101+
| [isInt](../logic-apps/workflow-definition-language-functions-reference.md#isInt) | Return a boolean indicating whether the string is an integer. |
101102
| [lastIndexOf](../logic-apps/workflow-definition-language-functions-reference.md#lastindexof) | Return the starting position for the last occurrence of a substring. |
102103
| [length](../logic-apps/workflow-definition-language-functions-reference.md#length) | Return the number of items in a string or array. |
103104
| [nthIndexOf](../logic-apps/workflow-definition-language-functions-reference.md#nthIndexOf) | Return the starting position or index value where the *n*th occurrence of a substring appears in a string. |
@@ -2538,6 +2539,35 @@ int('10')
25382539

25392540
And returns this result: `10`
25402541

2542+
<a name="isInt"></a>
2543+
2544+
### isInt
2545+
2546+
Return a boolean indicating whether the string is an integer.
2547+
2548+
```
2549+
isInt('<string>')
2550+
```
2551+
2552+
| Parameter | Required | Type | Description |
2553+
| --------- | -------- | ---- | ----------- |
2554+
| <*string*> | Yes | String | The string to examine |
2555+
|||||
2556+
2557+
| Return value | Type | Description |
2558+
| ------------ | ---- | ----------- |
2559+
| <*boolean-result*> | Boolean | A boolean indicating whether the string is an integer |
2560+
2561+
*Example*
2562+
2563+
This example tests a string that represents an integer:
2564+
2565+
```
2566+
isInt('10')
2567+
```
2568+
2569+
And returns this result: `true`
2570+
25412571
<a name="item"></a>
25422572

25432573
### item
@@ -5320,4 +5350,4 @@ Here's the result: `Paris`
53205350

53215351
## Next steps
53225352

5323-
Learn about the [Workflow Definition Language](../logic-apps/logic-apps-workflow-definition-language.md)
5353+
Learn about the [Workflow Definition Language](../logic-apps/logic-apps-workflow-definition-language.md)

0 commit comments

Comments
 (0)