Convert Text or String to Number or Integer using Power Automate Microsoft Flow

Convert Text or String to Number or Integer in Power Automate Microsoft Flow. Log in to Microsoft Flow and create a new Instant Flow. Name it accordingly. Add a new step to initialize a string variable.

We will be printing both values string and converted integer for your understanding. Add a new Compose Step and give the initialized string variable as input. Select the variable name from the Dynamic content.

Let us see the output of this Compose for now. Save and run the flow manually. Open the Compose to see its output. Click on Show raw outputs. You can also click on Show raw inputs as well. Both the values will be the same for Compose.

You can see that the string number value is surrounded by double quotes. That means it is of string data type.

Click on Edit and add another Compose step. Here we will show the converted integer value. Use the below expression to convert the string to an integer.

int(variables('myStringNumber'))

Below is what the complete flow looks like.

Save the flow and run it to check the second Compose output from the Show raw outputs. You will see that, now, the string number is not surrounded by the double quotes resembling integer data type.

Thank you All!!! I hope you find this useful. To Conver Integer to String, visit here.


One thought on “Convert Text or String to Number or Integer using Power Automate Microsoft Flow

Add yours

Up ↑

%d bloggers like this: