Store your files in the Common Data Service with Flow

In general I will store my files in SharePoint. As SharePoint’s document management capabilities of SharePoint match what I need. Document Libraries offer the option to store files and manage my files better than most other document stores. I do however sometimes need to store files in a different location, away for SharePoint. Today I had a look at storing documents in the Common Data Service using Microsoft Flow.

I started by taking a file stored in SharePoint.

Get file content

Before I go any further it is important to understand what the Get file content action returns.

File content in run mode

The File Content returned contains two pieces of data. The type of the content and the actual file content.

Store your files

We need these to create the file in a Note in the Common Data Service.

Store your files using the Notes in Flow

Now when we check in Dynamics the data is there.

Note in Dynamics

Or when I have a further look at the note that I created I can find my file back:

Note in dynamics showing excel file

Just to make sure that I can get my file back out of the Common Data Service I’m going for the reverse process. I am getting the note back using the Get record action and then I create the file in SharePoint with a new name.

Create Copy of file

When I now look in SharePoint my new file can be opened.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: