web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Error when downloading...
Power Automate
Suggested Answer

Error when downloading files from SFTP - File Path error

(0) ShareShare
ReportReport
Posted on by 2

Hello all, I would like to start off by saying that I am very new to Power Automate, this is my first attempt so I could be missing quite a few details.

I am trying to download files from an SFTP via power automate. I have the flow created, I can connect to the FTP and view the contents that I need to download but when it actually tries to download, It fails on the first file with error:

Microsoft.Flow.RPA.Desktop.Modules.SDK.ActionException: Can't download file: /XXXXXX/XXXXXXX/xxxxxx/xxxxxx.pdf. Error while deducing the file paths to use for the local copies.
at Microsoft.Flow.RPA.Desktop.Modules.FTP.Actions.Utilities.FtpUtilities.DownloadSingleFile(IFtpConnection connection, FolderObject downloadInto, String ftpFileDirectory, String fileName, FtpTransferType transferType, IfFtpFileExists ifFileExists, Boolean locateDir, String ftpRootDirectory)
at Microsoft.Flow.RPA.Desktop.Modules.FTP.Actions.Utilities.FtpUtilities.DownloadFiles(IFtpConnection connection, List`1 remoteFilePaths, FolderObject downloadInto, FtpTransferType transferType, IfFtpFileExists ifFileExists, Boolean locateDir, String ftpRootDirectory)
at Microsoft.Flow.RPA.Desktop.Modules.FTP.Actions.DownloadFtpFileAction.Execute(ActionContext context)
at Microsoft.Flow.RPA.Desktop.Robin.Engine.Execution.ActionRunner.Run(IActionStatement statement, Dictionary`2 inputArguments, Dictionary`2 outputArguments)

 

 

It creates the File in my downloads folder but there is no content, basically a corrupted file. I also noticed that sometimes it creates a folder named "Remote Desktop" with a subfolder named "TemporaryRDStorageFiles-{4B369669-1B6C-4B6F-98ED-EFA7606CA474}) and the files within this subfolder but power automate desktop still errors out. 

 

screenshot of flow: 

 

Osrid_0-1646930812588.png

 

 

Am i missing something here? Any help is appreciated. 

I have the same question (0)
  • VJR Profile Picture
    7,635 on at

    I guess the Files variable you have used is a datatable and so you might want to use a For each loop to iterate through each of the files and then download them within the loop.

     

    Having said that, if you have a pattern you can also give the extension and also with a wild card character.

    Have a look at this video if not already seen.

     

     

  • Osrid Profile Picture
    2 on at

    Hi, thank you for taking a look.

    I tried the for loop but got the same result. I watched the video and i am following the same steps but i still get the error. starting to think it might be a bug. 

  • VJR Profile Picture
    7,635 on at

    Hi @Osrid 

     

    I still think it could not be a bug.

    Could you share the screenshot of the inside of the FOR loop.

    Also can you print in a Display box and see what is the string being passed to the Download Files inside the For loop.

  • Suggested answer
    HardEight Profile Picture
    2 on at
    I have a PAD flow that has ran flawlessly for years at this point. Suddenly started getting the "Error while deducing the file paths to use for the local copies" error. Found only this thread mentioning it, everything else was about file paths that are too long. This is copying down from SFTP to a local folder on the C:\ drive, so the length wasn't an issue. 
     
    Anyway, rebooting the VM fixed it.  

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard