Hey @RayJ30
You do not need to worry about the SOAP connector(Ignore it).
Follow the Steps 3a to 3e in the article.
Step 3a: The SharePoint “When a file is created or modified (properties only)” does not provide us the File extension for the file. To get the file extension we need to perform the steps shown below.
Step 3b: Add the “Initialize Variables” action to the Flow Canvas and Rename it to “Get File Name”.
- Name: Set it to “Filename“.
- Type: Set it to “String”.
- Value: Add “File name with extension” the output from the “When a file is created or modified (properties only)” action.
Note: If you are new to Power Automate (Microsoft Flow), please refer to the article on how to use expressions in flow actions.
Step 3c: Add the “Initialize Variables” action to the Flow Canvas and Rename it to “Get File Name Length” .
- Name: Set it to “Filelength“.
- Type: Set it to “Integer” .
- Value: Set it to Expression “length(variables(‘Filename’))“.
Step 3d: Add the “Initialize Variables” action to the Flow Canvas and Rename it to “Get Extension Length”.
- Name: Set it to “Extensionlength“.
- Type: Set it to “Integer”.
- Value: Set it to “Expression” “sub(variables(‘Filelength’),lastIndexOf(variables(‘Filename’),’.’))“
Step 3e: Add the “Initialize Variables” action to the Flow Canvas and Rename it to “Get File Extension”.
- Name: Set it to “Get File Extension“.
- Type: Set it to “String”.
- Value: Set it to “Expression” “substring(variables(‘Filename’),lastIndexOf(variables(‘Filename’),’.’),variables(‘Extensionlength’))“.
Step 3f: Add the “Compose” action to the Flow Canvas and Rename it to “Replace . From the Get File Extension”.
- Inputs: Set it to “Expression”
“replace(variables(‘Get File Extension’),’.’,”)“.
At the end of the above step we will have the “File Extension” and we will can use in you in Power Automate, condition, switch statement.