Exporting and Importing SharePoint Designer 2013 List Workflow
Although story of SharePoint Designer 2013 is slowly reaching its end and it is known for sure that shortly after 2020 will be deprecated, still there are many clients using it and developing their solutions with its help.
I recently found myself in a situation, where I needed somehow to create three instances of the same workflow (with small differences) for the same, SharePoint list. I started googling, but nothing helpful arrived. Then I tried to just export the workflow to Visio, rename it, and import again. Using that approach however only changed the name of the original workflow, not really created a new one.
How it was done in SharePoint Designer 2010?
Then, having hints how it was done in SharePoint 2010 (source):
- In SharePoint Designer 2010, click on your completed List Workflow.
- Click on “Save” and “Publish” for the completed List Workflow.
- Next, click on “Export to Visio”. Save the file as CompletedWorkflow.vwi or any preferred name.
- Then create a new “similar” list on the current site or on a new site collection. There is no way to import the exported visio into this new list.
- In SharePoint Designer 2010, click on this new list and then click on “List Workflow” to create a new workflow for this new list.
- Please make sure that you do not add any workflow steps!
- Click on “Save” and “Publish” for this empty List Workflow.
- Then, click on “Export to Visio” and save this as EmptyWorkflow.vwi or any preferred name.
- Rename both the vwi files by adding “.zip” extension. The files should be CompletedWorkflow.vwi.zip and EmptyWorkflow.vwi.zip.
- The objective is to replace the “workflow.xoml.wfconfig.xml” file from the EmptyWorkflow.vwi.zip into the CompletedWorkflow.vwi.zip.
- It is likely that you cannot replace it directly. Copy the file out to the desktop and then copy the file into the other zipped folder.
- Remove the “.zip” extension from the CompletedWorkflow.vwi.
- With this, we have a working importable visio List Workflow.
- Back in the SharePoint Designer 2010, close all the workflow tabs.
- Click on the “Import from Visio” and select the CompletedWorkflow.vwi.
- You have successfully export and import the List Workflow.
I thought I should do the same: I opened the exported Visio as an archive, copied definitions from an target workflow into a blank one, saved it, but… it turned out, that the file is corrupted and cannot be opened by Visio as well as imported back by SPD (possibly this is feasible, but I didn’t have too much time for investigations).
How should be done in SharePoint Designer 2013?
The solution was far more easier. All you have to do is…
- Export the existing workflow into a Visio file.
- Open the exported file in Visio.
- Copy its contents.
- Create a new Visio file and paste contents.
- Save the pasted workflow as a new file, under a new name.
- Import it back using SharePoint Designer.