cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AndriiKa
New Member

Sharepoint Flow - Create a folder on FTP server

 

Hi all,

 

is there a chance to create a folder on FTP server by using SharePoint Flow?

 

My current task is to copy some files from SharePoint Document Library to FTP by using Flow, this works fine. In addition I want to automatically create the same folders' structure, that I have in SP Document Library, on FTP site; I can get the path by using "Path" variable but I do not see any options how to create a folder on FTP server, any ideas?

 

Many thanks,
Andrii

4 REPLIES 4
v-xida-msft
Community Support
Community Support

Hi @AndriiKa,

 

Could you please share a screenshot of your flow’s configuration?

Do you want to copy all files of a SharePoint library to FTP Server folder?

Or copy the file to FTP Server folder when a file is created in SharePoint library?

Further, do you want to automatically create the folder structure and copy the file into it? Is it true?

 

Creating a folder action of FTP Connector is not supported in Microsoft Flow currently, but you could consider take a try with the following workaround:

  • Add a “When a file is created or modified (properties only)” trigger.
  • Add a “Get file metadata” action, File Identifier field set to Identifier dynamic content of above trigger.
  • Add a “Get file content” action, specify Site Address, File Identifier field set to Identifier dynamic content of the trigger.
  • Add a “Create file” action, Folder path set to following formula:
/Folder path dynamic content of the trigger

 

File name set to DisplayName dynamic content of “Get file metadata” action.

 

File content set to File Content dynamic content of “Get file content” action.

 

Image reference:18.JPG

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hello Kris,

 

thank you for prompt reply!

 

Currently I use exactly the same flow 🙂 as you showed, so I can create files on FTP in a root or chosen directory. My plan is keep the same folders structure on FTP site that I have in SP DL.

 

Hope Microsoft will add "FTP - Create Folder" action soon 🙂

 

Many thanks! Merry Christmas!!!

 

BR,
Andrii

 

 

Primarystorage
Frequent Visitor

I have tried coping your approche, but I get the follwing error message.

 

"status": 404,
"message": "A reference was made to a file or folder which does not exist.\r\nclientRequestId: 98a77416-a950-4e42-a840-8cc15def4e07",
"source": "sftp-ne.azconn-ne.p.azurewebsites.net"
 
 
I am using a dynamic path function, but the SFTP server doesnt create the Path automaticlly, it always says it cant find the folder. Which is true, because I was under the impression that the directory would be created.
 
Any help would be appricated.

Have same issue, can only get it working if we make the folders first which isn't a good solution for us.

Helpful resources

Announcements
October Events

Mark Your Calendars

So many events happening this month - don't miss out!

 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Users online (4,647)