SharePoint-Server-2010-logo

Create folder and copy a file to that folder in SharePoint Designer Workflow

[ProjectCasemanagement solution]

In this Video I will show how you can create a simple project folder and the copy a template file into that folder. The idea came from a comment on this blogpost, that shows more in-depth how to create folders and subfolders. If you like the video or have questions, leave me a note in the comment section.

Step By Step guide

  1. Create a Column called “Destination” on the “Documents” Library that holds the template file
  2. Create a Column called “Destination” on the “Project Documents” Library that holds all the project folders
  3. Create a SharePoint Designer workflow that updates the template file when it arrives at the “Project Documents” Library
  4. Create or tweak you Workflow that creates the project folder so that it:
    1. Updates the template file
    2. Copies the template file
    3. Sets the template file back to normal
11 replies
    • Simon Kirkby
      Simon Kirkby says:

      Hi Ulrich,

      I eventually found time to look at this again. I can confirm that your method works with Document sets as well as folders. My mistake was not using a 2010 workflow as SharePoint Online only seems to execute 2010 workflows when a workflow creates a new document item in a library, 2013 don’t even if the workflow is flagged to execute when a new library item is created.

      Simon

      Reply
  1. Beau Landry
    Beau Landry says:

    We have SP 2013 with SPD 2010 workflow. I tried all the steps without any luck. Are you positive I can move a file into a folder of another document library using a SP 2010 workflow? We keep having issues with updating “Path and Name”.

    How does the template “Title” field get populated? I see that you’re populating the “Destination” column with the “current item:Title” value. Thanks!

    Reply
    • Ulrich Gerting Bojko
      Ulrich Gerting Bojko says:

      Hi Beau

      Thank you for your question. I am very positive this works. But remember a few things:

      1. I am copying the file, not moving
      2. “Path and name” needs a destination column that has content in it.
      3. “Title” should allready be set in the template file.

      I hope you get it to Work.

      Best regards, Ulrich

      Reply
      • Beau
        Beau says:

        Thanks for your quick response! I’m still having issues getting it to work. Has anybody tried this with a SharePoint 2010 workflow all the way through? In the video, half of the process is configured using SharePoint 2013 workflow. I can get the new folder created but I’m unable to get the “template” file to copy to the Project Documents library and then move into the new folder I created. I get the following message, “The workflow could not copy the item. Make sure the source and destination lists have the same columns and column settings.” I have the Destination column being populated with the title of the “template” document. Any help appreciated, thanks!

        Reply
  2. Supriya Tenany
    Supriya Tenany says:

    Hi, I’m trying to perform a weekly task to copy a file into a folder in the same document library, and update the name of the copied file. Is that possible?

    Reply
    • Ulrich Gerting Bojko
      Ulrich Gerting Bojko says:

      Depending on your platform, there are several ways to go about this. You could write a powershellscript that does that. You could set a waiting period on your workflow. So the workflow runs, the waits 7 days, starts another instance of the same workflow and the closes down. Then it will seem like it runs every 7 days, bu it just runs once, waits for 7 days and the runs another Workflow and shuts down. The second workflow needs the same behavior offcource.

      Reply
      • Supriya Tenany
        Supriya Tenany says:

        I could perform the same actions in 2 different stages of the workflow wherein each of them waited for 7 days and transitioned to the other stage. However, what I need to do is when once the workflow is triggered on an item, in each stage, it should first create a copy then move that copy into a folder at the root. What I’m able to do now is create a copy and move ‘the’ item into the folder, which isn’t what I want. How can I deal with this?

        Reply
  3. Rutul
    Rutul says:

    Hi Ulrich,
    Your video is indeed helpful, however, in a case where sharepoint is integrated with CRM, and folders are created using CRM, is there a way to copy files (One Note and Excel files) from Document Library (Templates) to the Project folder (This folder is created when a project is created in CRM) that is created under Projects Library?

    Reply

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply