mscrm-addons.com logomscrm-addons.com logo
  • Release History
  • Knowledge Base
  • Documentation
  • Contact Support
  • Release History
  • Knowledge Base
  • Documentation
  • Contact Support
home/Knowledge Base/DocumentsCorePack(DCP)/How to automatically create SharePoint folders and subfolders using DocumentsCorePack

How to automatically create SharePoint folders and subfolders using DocumentsCorePack

6355 views 2 Updated on January 24, 2025

This article explains How to automatically create SharePoint folders and subfolders using DocumentsCorePack (DCP). Depending on the context, the following options are provided:

  1. Via Power Automate: The CreateSharePointFolders (V3) action allows you to create folders and subfolders on your integrated Dynamics 365 SharePoint with Dataverse data.
  2. Via Classic Dynamics 365 workflows: The AutoMergeWorkingItem comes with a CreateSharePointFolder option (see Step-by-step description below).

Let’s see how to automatically create SharePoint folders and subfolders using DocumentsCorePack.

Via Power Automate

In your flow add a new step and look for the DocumentsCorePack action Create SharePoint folder (V3).

Figure 1: Look for Create SharePoint folder (V3)

The ❶ Row ID field is the unique identifier of the record to create the folders for and the ❷ Table Name. In our example, we are creating a folder for accounts. Thus we choose “Account” for the tabla and the GUID of an account as the Row ID.

Figure 2: Create SharePoint Folder

In the ❸ Folder Names Item section, you have the possibility to create a folder structure, in this example, we decided on two folders and two subfolders in one folder. Learn more.

Please note: There is a Syntax to follow

“;” separates list of folders
“/”  creates subfolders

Additionally, you can choose the ❹ user who should run this operation and the ❺ document location to create the folders in. Don´t forget to ❻ Save.

Step-by-step description for a classic Dynamics 365 workflow to automatically create SharePoint folders and subfolders

Step 1: Automatically create folders for accounts once created.

Figure 2: Create New Process

Step 2: Define the following settings

❶ Process name
❷ Category
❸ Entity
❹ Confirm with [OK]

Figure 1: Define settings for process/workflow

Step 3: This window opens. Now add the next step Create Record to your workflow and name it, such as Create Folder.

Add the next step (Create Record) to the process.
Figure 4: Add step to the process

Step 5: Now click the drop-down button and look for the MSCRM-ADDONS.com AutoMergeWorkingItems.

Select the AMWI from the drop-down.
Figure 5: Add the AMWI

Step 6: For further steps, open the Set Properties and fill out the mandatory fields, including ❶ Name and ❷ AutoMergeAction. Then insert the ❸ PrimaryRecordURL. Put the cursor in the PrimaryRecordUrl field and select on the right side {Record URL(Dynamic)(Account)}. Press the ❹ [Add] button.

Open the Set Properties and fill out the mandatory fields.
Figure 6: Set Properties

Step 7: Now scroll down to Create SharePoint Folder, where you can define how your folder and subfolder structure are organized.

How to automatically create SharePoint folders and subfolders using DocumentsCorePack
Figure 7: Determine a folder structure

Please note: In the example above, the folder structure looks like this:

Syntax:

  • “;” separate list of folders
  • “/” creates subfolders

Example:

FOLDER/subfolder 1;FOLDER/subfolder 2;FOLDER1/subfolder 1

Creates folders as follows:

 
How to automatically create SharePoint folders and subfolders using DocumentsCorePack

Step 8: Now press the [Save and Close] button in the left top corner of this window.

 
How to automatically create SharePoint folders and subfolders using DocumentsCorePack
Figure 8: Don´t forget to save!

Step 9: Back in the Power Apps window you have to activate the process.

How to automatically create SharePoint folders and subfolders using DocumentsCorePack
Figure 9: Activate Process

Execute workflow:

Create a new account in your system. Once the workflow is finished you should see the following folder structure on the newly created document location for the account:

How to automatically create SharePoint folders and subfolders using DocumentsCorePack
Figure 11: Result of the workflow

That’s it! We appreciate your feedback! Please share your thoughts by sending an email to support@mscrm-addons.com.

Was this helpful?

2 Yes  1 No
Related Articles
  • Locating Raw Inputs and Outputs in Power Automate
  • Step by Step: How to execute an OCA in a Power Automate flow 
  • Stop Losing Time & Money: How Manual Document Processes Hurt Your Business
  • Debugging the Template Design Office Add-In 
  • Updating Legacy SharePoint Connections 
  • Deploying DocumentsCorePack: Setup, Automation, and Real Business Impact in Dynamics365
Latest Articles
  • Recap: Community Summit 2025
  • Locating Raw Inputs and Outputs in Power Automate
  • Step by Step: How to execute an OCA in a Power Automate flow 
  • Stop Losing Time & Money: How Manual Document Processes Hurt Your Business
  • The Hidden Cost of CRM Storage — And How to Eliminate It 
Popular Articles
  • DocumentsCorePack Template Designer – Getting Started
  • Step-by-Step: How to configure a One-Click-Action
  • Application Access for Dynamics 365
  • How to find your environment’s unique name in Microsoft Dynamics 365
  • How licenses are counted
Top Rated Articles
  • “Undefined”-labels in Chrome and Edge 114 and higher
  • How to insert Condition Fields in DocumentsCorePack Templates designer
  • Important information for Dynamics 365 online customers using DocumentsCorePack and/or AttachmentExtractor
  • How to activate the DocumentsCorePack Connector for PowerApps & Microsoft Flow
  • How licenses are counted
Categories
  • *News and General Infos* 66
  • Webinars 46
  • Template Designer(DCP 197
  • DocumentsCorePack(DCP 263
  • TelephoneIntegration (TI 65
  • AttachmentExtractor (AE 76
  • PowerSearch (PS 50
  • ActivityTools (AT 61
  • SmartBar (SB 54
  • GroupCalendar (GC 47
Our Vision

“We see it as our purpose to provide products that simplify and speed up our customers’ Microsoft Dynamics 365 experience.”

Knowledgebase
LogIn
mscrm-addons.com
  • Products
  • Online Shop
  • Downloads
  • My Account
About Us
  • About Us
  • Case Studies
  • Newsletter
  • Partner Program
  • Contact
Support
  • Support
  • Terms & Conditions
  • Documentation
  • Webinars
  • Legal Documents
  • Impressum
  • © 2025 www.mscrm-addons.com. All Rights Reserved.