Hello,
I have a data gateway setup and am successfully pulling a file from it and uploading its contents to SharePoint. I want to delete the on premise file after the process, however I cannot get it working. I have tried using the delete file function and placing the 'list files' ID, Path, Name, even DisplayName and no luck. It either says it cannot find the file, or when I choose Name, it says success but the file does not delete.
Here is the error.
"body":{"status":400,"message":"The requested action could not be completed. Check your request parameters to make sure the path 'E:\\Code\\Powershell\\Career Services Upload\\Upload/Alumni-1-27-2021.csv' exists on your file system.\r\nclientRequestId: 514b3371-62c4-48a7-ad32-203494d005bb","error":{"message":"The requested action could not be completed. Check your request parameters to make sure the path 'E:\\Code\\Powershell\\Career Services Upload\\Upload/Alumni-1-27-2021.csv' exists on your file system."},"source":"filesystem-wus.azconn-wus-01.p.azurewebsites.net"}}
That path does work on my file system, and is working on my get file content component.
Thanks.
@Kthomas I am curious if you ever found the issue? I am encountering the same problem. I have a logic app where I am connected to a local file share data gateway -- I am able to pick up a file, get the file content, create a new file in a different ftp location with the file content, but then the file won't delete from the local file share on my data gateway. I am using the List of File Paths to specify which file to delete. Here is my workflow with the File Delete action:
The strange part is that the workflow completes successfully if I am picking up files with the extension .txt. However, the files I am trying to pick up are .csv and for whatever reason, this causes the file deletion to fail with the same error message you receive. I also tried using the List of File Names to specify the file to delete, but got the same result as you: Successful run but the file was not actually deleted.
Curious if you found a solution to this strange issue?
Thanks!
Meredith
Hi @Kthomas
I've tried every effort to reproduce the error you get, but still couldn't reproduce it.
Every error occurs at the 'Get file content' action.
I previously thought that there is a bug in 'delete file' action. But every time when the file content has been got and the condition works well, 'delete file' works quite well.
Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks for the feedback. Path did not work either.
{"status":400,"message":"The requested action could not be completed. Check your request parameters to make sure the path 'E:\\Code\\Powershell\\Career Services Upload\\Upload/Alumni-1-27-2021.csv' exists on your file system.\r\nclientRequestId: 57fd9cf4-33c9-4bfa-825a-7d69e3d97b95","error":{"message":"The requested action could not be completed. Check your request parameters to make sure the path 'E:\\Code\\Powershell\\Career Services Upload\\Upload/Alumni-1-27-2021.csv' exists on your file system."},"source":"filesystem-wus.azconn-wus-01.p.azurewebsites.net"}}
Hi @Kthomas
The value you should put in the ‘File’ in ‘Delete file’ action should be the path of the file which you can get from dynamic content.
Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.