Power Automate Fundamentals – Series #1 – Quick Conversion from UTC To IST
In Power Automate, functions place an important role for conversions, to quickly see how to Convert UTC Time to IST Time we use Instant Cloud flow.
Step 1 :
Login to the required Power Apps environment using URL make.powerapps.com by providing user name and password and click on Flows on the left hand side as shown in the below figure.
Figure 1 :
Step 2 :
After Step 1, click on New Flow and then select Instant Cloud Flow as shown in the below figure.
Figure 2 :
Step 3 :
After Step 2, a new popup will be shown with title Build an instant cloud flow in that popup to the right side various triggers are shown, select Manually trigger a Flow and then click on Create Button as shown in the below figure.
Figure 3 :
After Step 3, a new screen will be displayed and provide the name Quick Conversion of UTC to IST and click on Save button and click on New Step as shown in the below figure.
Figure 4 :
Step 5 :
After Step 4, a small window with title Choose an operation will be displayed with a search box. In that search box search for Compose and select Compose Action as shown in the below figure.
Figure 5 :
After Step 5, Action Compose will be shown with Input’s text box, select that text box and a related window will be shown in the right-hand side- with 2 tabs, Dynamic Content and Expression. Select Expression Tab and in fx textbox provide expression
and click on OK which will show time in UTC Time zone as shown in the below figure.
Figure 6 :
Step 7 :
After Step 6, Add another Action Compose and in Inputs of this new compose give name as “IST Time” and provide the expression
convertFromUtc(utcNow(), ‘India Standard Time’)
where the function covertFromUtc have 2 parameters in the first parameter provided current UTC Time and the 2nd parameter provided the string ‘India Standard Time’that is required for final result time zone and click on OK as shown in the below figure.To remove confusion renamed compose action present in Step 6 to UTC Time and click on Save
Figure 7 :
After Step 7, to test this flow click on Test button at the top of the screen, if the flow Is fine then we should see next screen as shown in the below figure
Figure 8 :
After Step 8, a small window opens up select Manually option and click on Test button as shown in the below figure
Figure 9 :
After Step 9, another window comes with text Run flow and click on Run flow Button as shown in the below figure
Figure 10 :
After Step 10, flow run started successfully message and click on Done Button as shown in the below figure
Figure 11 :
Step 12 :
After Step 11, window gets refreshed and you could see all the actions ran successfully with green tick mark as shown in the below figure
Figure 12 :
Step 13 :
After Step 12, to test whether the values are changed to IST Time zone from UTC , open the actions and see the time stamps which infers conversion happened successfully as shown in the below figure
Figure 13 :
- Please make sure to save the flow for every operation.
- After expressions are given make sure to click either on OK or Update and see whether the value appears as expected in the input box.
- In case of any errors flow checker will provide you list of errors which is a button beside Run button.
- Refer to the time zone Id’s in this example we used “Indian Standard Time”, if you want to use others then refer to the Microsoft documentation https://docs.microsoft.com/en-us/previous-versions/windows/embedded/gg154758(v=winembedded.80)?redirectedfrom=MSDN
In this way one can easily test Power Automate Functions with the usage of Instant cloud flow and by manually trigger a flow within minutes.
About the Author :