I want to save the image taken from the camera control in PowerApp in the Notes entity of Dynamics crm 365.
For this I have taken help of: https://www.techmikael.com/2017/05/an-even-more-clever-workaround-for.html
In the compose action of the flow I have formula:-
"@base64ToBinary(replace(triggerBody()['Createfile_FileContent'],'data:image/jpeg;base64,',''))"
The notes entity record is getting created with image as attachment. But I am getting below error when opening the image:-
"The input is not a valid Base-64 string as it contains a non-base 64 character, more than two padding characters, or an illegal character among the padding characters."
Please help.
Hi @Ancy,
Could you please share a bit more about your scenario?
Do you want to pass an image captured via Camera control (within an app) to a flow, then attach it to Notes entity record?
I think there is something issue with the base64ToBinary() function within the formula that you mentioned. Please take a try with the dataUriToBinary() function instead of base64ToBinary() function, then check if the issue is solved.
Please type the following formula within the Inputs field of the "Compose" action:
"@dataUriToBinary(triggerBody()['Createfile_FileContent'])"
then check if the issue is solved.
Please also check the following blog for more details:
Best regards,
Kris
This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
User | Count |
---|---|
204 | |
71 | |
51 | |
49 | |
20 |
User | Count |
---|---|
260 | |
121 | |
85 | |
76 | |
72 |