question

AnanyaDixith-4766 avatar image
0 Votes"
AnanyaDixith-4766 asked WendyLi-MSFT edited

validate the flow of file creation in sharepoint

Hi,
Im working on simple flow, I want validate the flow

Im trying to create file in Sharepoint through logic app.
I can able to create file in sharepoint, but how validate the flow if the file is already exists in sharepoint.

How to handle the error status: 400

204221-image.png
204167-image.png

raw output
204168-image.png


Please help me out.,how to handle this error


office-sharepoint-onlineazure-logic-apps
image.png (39.9 KiB)
image.png (23.3 KiB)
image.png (9.7 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

KamleshKumar avatar image
0 Votes"
KamleshKumar answered

Hi There,

Thank you for asking this question on the Microsoft Q&A Platform.

Before Create file check if file is present in SP folder. You can use 'Get files' for that. I tried to create the same scenario for you and hope this could help you,

Flow could be look like,

Condition filter -- length(body('Get_files_(properties_only)')?['value'])

204242-image.png

LogicApp Run Result if incase file is not present,

204183-image.png

LogicApp Run Result if incase file is present,

204237-image.png

Regards,
Kamlesh Kumar
BizTalk Techie

If this answer solved your problem, please click the Verify Answer button (found below the answer) to help other users who have the same question.





image.png (39.5 KiB)
image.png (30.5 KiB)
image.png (30.6 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.