SKIP Function
What is the SKIP function?
SKIPFUNCTION is used to skip characters in the string (SINGLE NAME) and collection(ARRAY). You can get a second after skipping the first character using the skip function.
USAGE WITH ARRAY = skip a character like “Sajid”
USAGE WITH STRING = skip a single letter like the name is ‘Sajid’ it will skip those letters that you pass in parameter i.e (s)
Description:
In this guide, we will discuss how to use the float function in power automation. Let us create a new flow. To create a new flow follow the following instructions:
Go to power Apps:
Navigate to Flows:
After clicking new flow, select ‘Instant Cloud flow’ form the dropdown:
After clicking new flow, select ‘Instant Cloud flow’ form the dropdown:
Finally set its name and select ‘manually’ as flow trigger point:
In the below screenshot we set the Name of flow and its trigger point which is ‘Manually trigger a flow. Finally, click on the create button to create a new flow.
First, add INITIALIZE VARIABLE ACTION:
To initialize a variable select initialize variable action from the actions set. Then set its properties the same as mentioned in the screenshot.
We initialize a variable having an array name. we will skip some names using secondary parameters in the function
NOW ADD A ‘COMPOSE ACTION’ TO PERFORM THE SKIP FUNCTION:
In the given or skip function, I pass (2) as a secondary parameter. Basically, I want to tell the function to take out the first 2 names from the given array
CODE:
skip(variables('ARRAY NAMES'), 2)
OUTPUT:
Here is the array which was given as input. You can see here first two names are missing. ‘MUHAMMAD’ and ‘SAJID’. Both names are missing
ADD ANOTHER ‘COMPOSE ACTION’ IN THE GIVEN FLOW:
This is composed is for string values like we will give or put the name in the value and use the skip function to skip some letters from the name
In the function, I tell that take out or remove the first 4 letters from the given string or name
CODE:
skip(variables('STRING NAME'), 4)
OUTPUT:
You can see the result in the output. The given value was ( MUHAMMAD SAJID) but now we have MMSDSAJID means to say the first 4 letters are missing from our given value. Because we pass the second parameter like 4
0 Comments
Thanks for commenting. Your comment will be live soon after approval.