Hello,
I want to create a flow with a trigger when a file is created on sharepoint and use file content in next actions. So firstly I created "When a file is created in a folder" trigger, then I created a csv file and uploaded it:
and everything went ok. I can see file content just fine.
Now, I decided I need mail of person who created the file. I changed the trigger to "When a file is created (properties only)" and then used its dynamic functions to put "Identifier" in "Get file content". I expected the same result but the file content is different.
What I need in the output is:
SIMF
ATSF
IMOF
BG1F
not
{
"$content-type": "application/octet-stream",
"$content": "U0lNRg0KQVRTRg0KSU1PRg0KQkcxRg0K"
}
How can I fix this?
Solved! Go to Solution.
Hi @Radek1 ,
This is because Get File Content will return the binary.
If you convert to base64 and then to string, you will see your original text
@base64ToString(base64(outputs('Get_file_content')?['body']))
--------------------------------------------------------------------------
If I have answered your question, please mark my post as a solution
If you have found my response helpful, please give it a thumbs up
Connect on LinkedIn
Hi @Radek1 ,
This is because Get File Content will return the binary.
If you convert to base64 and then to string, you will see your original text
@base64ToString(base64(outputs('Get_file_content')?['body']))
--------------------------------------------------------------------------
If I have answered your question, please mark my post as a solution
If you have found my response helpful, please give it a thumbs up
Connect on LinkedIn