One-Click-Actions (OCAs) are predefined configurations in the DocumentsCorePack (DCP) Dialog designed to simplify and accelerate document creation and distribution in Dynamics 365 and PowerApps.
This guide walks you through the process of creating a One-Click-Action. Once a user selects one or more records within an entity and clicks ‘Create Document’, the configured One-Click-Actions will appear in the DCP Dialog.
Example: Accounting needs to generate PDF invoices, email them to customers, save a copy to SharePoint, and print a physical copy. An administrator can streamline this workflow by configuring a One-Click-Action – a compact automation that users can trigger with a single click.
Step-by-step video
Step-by-step description
This guide walks you through the process of creating a new OCA to email a PDF to a customer and save it in SharePoint.
Step 1: Opening the One-Click-Action Configuration
To begin, open your Dynamics 365 settings, go to Settings, select Advanced Settings, and under MSCRM-ADDONS select DocumentsCorePack and then the One-Click-Actions tab.
The main configuration window will open, displaying tabs for general DCP setup options.
❶ The buttons in this group allow you to edit, delete, or add an entity to the list.
❷ To find the entity you want to create OCAs for, type its name into the search box. If it does not appear in the list, click the New button to add it.
❸ Click on the entity you want to open. A new dialog will appear where you can create and manage OCAs for the entity. Take note that once an OCA has been created, it can always be edited.
To add an entity, click the New button, and follow the steps below.
❶ In the window that appears, select Single to create a new Single Action OCA.
❷ Use the Entity drop-down menu to select the appropriate entity.
❸ Enter a name for your OCA in the Name field.
❹ Click Create to save your selections.
You will then go through four configuration screens—General Settings, Template Settings, Processing Settings, and Review Settings—to set up your OCA in detail.
Step 2: General Settings of One-Click Actions
In the General Settings window, you have four sections.
❶ Name: Edit the name you previously entered for your OCA (as shown below).
❷ Description: Add a description to help users understand the purpose of the OCA when they run in.
❸ Set as default configuration: Set this OCA as the default configuration, meaning this OCA will run automatically whenever the user clicks Create Document.
❹ Hide in dialog: Hides the OCA from the user.
Use the buttons in the lower-right corner of the page to perform the following actions as needed:
❺ These buttons let you navigate to the next or previous step. Once you are satisfied with your configuration, proceed to the next step.
❻ Click the Save button to save changes to your OCA.
❼ Click the Delete button to delete your OCA.
❽ Click the + button to configure display rules.
Note: OCAs can be hidden or made visible to certain users via display rules.
Step 3: Template Settings
The Template Settings section allows you to configure your template selection in detail. There are multiple template selection options available, each corresponding to a different scenario:
a. Allow User Selection
b. Predefine Template
c. Use MultiPart
d. ZUGFerd/Factur-X (Multi Part)
a) Allow User Selection
The Allow User Selection option defines an OCA that enables users to choose a template themselves when running the OCA.
To view this from a user’s perspective, go to your Account Entity in Dynamics 365, select the Account Name, and click Create Document.
The DCP Dialog opens. In the upper right corner, click the middle icon to access OneClickActions Configuration.
The One-Click-Actions Configuration window will then open, allowing you to select your OCA from the list on the left and selecting Allow User Selection from the template selection drop-down menu.
In this case, for Allow User Selection, there is only the feature: Conditional Template Group setting. Follow the steps below to enable it.
- To the right of Conditional Template Group, click Open to launch a dialog where you can link entity attributes to template groups. Template groups are collections of templates—often representing operational aspects—defined within the template designer.
- If the predefined attributes match those of the selected record, the OCA will present the user with context-specific template groups. This is especially useful when you want to limit available templates to those relevant to a specific department.
b) Predefine Template
❶ The second template type in the drop-down menu for Template Selection is Predefine Template. This allows the user to set a template to be used in advance, skipping the need to choose one later.
❷ Click in the Template field to open a lookup window to search for a suitable template that you want to set for the OCA and then Add it.
❸ Selecting the Edit Template checkbox enables you to modify the template before the document is generated.
❹ A Conditional Template Selection button is provided for this template type.
- You can select Open to the right of this button to launch a window where you can define templates that are conditionally shown to the user, based on attributes that must match those of the currently selected record.
- For instance, depending on the customer’s location, a template in the appropriate language can be automatically provided when the user initiates the OCA.
c) Use MultiPart
The third option in the drop-down menu is Use MultiPart. This template enables creation of compound documents—combinations of multiple components such as dynamic DCP templates and static files like PDFs. It supports both predefined and user-selected documents, allowing for flexible document assembly. MultiParts allow users to merge several documents into one single document, streamlining the process of creating comprehensive outputs.
A DocPart (document part) Type can be a Microsoft Word template (docx), a note, or a SharePoint URL pointing to a hosted document. Each DocPart can include a label and description, which are displayed to the user when running the OCA.
d) ZUGFeRD/Factur-X (MultiPart)
This feature is a version of MultiPart that assists in creating ZUGFeRD/Factur-X-compliant documents. Unlike standard MultiParts – which are typically used for invoice creation and require both a docx and XML template – this version is tailored to meet the unique structure and compliance requirements of these hybrid formats.
Differences to regular OCAs
When you select this setting, a multipart configuration will open, consisting of two parts: “ZUGFeRD pdf” and “ZUGFeRD xml”. Each part requires a template. In the “pdf” row, select a ❶ template that will display the visual contents of the document as a PDF. In the “xml” row, select a ❷ template that will be embedded as an XML file within the final PDF.
You can easily add optional components to the multipart setup, which will be merged with the final PDF. This is especially useful for including elements like cover pages or terms and conditions. Standard concatenation options are available by default.
Note: For more information on ZUGFeRD/Factur-X, please refer to this article.
Step 4: Processing Settings
In this step, you can specify the actions to be performed after the document is created. In the example shown in the figure below, the defined action is as follows:
❶ Send the Account_Overview as pdf.
❷ Attach the document as a note.
❸ Save it to SharePoint.
❹ Set your General Behavior preferences. There are 3 available options:
- Set configured settings as default.
- Hide configured settings.
- Disable configured settings.
❺ You can inherit the main behavior or:
- Do not save.
- Set as the default.
- Hide this setting.
- Show, but do not allow changes.
To proceed, click the arrow located at the bottom right of the screen to move to the next step.
Step 5: Review Settings of the One-Click-Actions
As illustrated in Figure 20, you can review your document, generate a PNG preview, and open the file automatically. Once all steps are configured, save your OCA.
Step 6: Test your One-Click-Action
When a Dynamics 365 user clicks on Create Document, they are automatically presented with the available OCAs. Users will only see OCAs for which they meet the predefined display rules.
Select your desired OCA, and depending on your chosen template, the corresponding windows in the following figures will appear.
a. Allow User Selection
b. Predefine Template
c. Use MultiPart
Below is a preview of the generated document. You can either make edits or complete the OCA.
Lastly, return to Dynamics 365 to access your generated template.






















