mscrm-addons.com logomscrm-addons.com logo
  • Release History
  • Knowledge Base
  • Documentation
  • Contact Support
  • Release History
  • Knowledge Base
  • Documentation
  • Contact Support
home/Knowledge Base/Template Designer(DCP)/How to sort data in DocumentsCorePack with the Relationship Designer

How to sort data in DocumentsCorePack with the Relationship Designer

1923 views 1 Updated on January 9, 2024

This article outlines how to sort data in DocumentsCorePack templates with the Relationship Designer.

Step-by-Step Guide

Step 1: Open Microsoft Word and navigate to the www.mscrm-addons.com tab. Next, click on the Insert MailMerge Fields button and prepare the data you want to sort, such as the fields shown in the example below.

Data you want to sort
Figure 1: Data you want to sort

Step 2: Next, navigate to the ❶ Additional tab in the DocumentsCorePack Template Designer. Select the data table you want to sort, which in this example is ❷ Contact (table1) and then click the ❸ Edit button.

Figure 2: Open the Relationship Designer

Step 3: The Relationship Designer window opens. Here you can define how you want to sort your data by adding the respective fields to sort by (see Figure 3) ❶.

The sorting priority is automatically determined by the ❷ order in the list (prior to v10.45 of the Template Designer it was defined by an integer value). All sorting entries can be ❸ rearranged with the up and down arrows and deleted with the minus sign.

Please note: If you are using fields from related records, the respective sorting field can only be edited within the ❹ correct relationship context.

New sorting element
Figure 3: Defining the sort order for retrieving related records

Please note: This function will sort all records before these are merged. After saving your template and merging it with Dynamics 365 data, the table should look like below.

Result of sorting data with DCP Relationship Designer

Figure 4: Resulting table with rows sorted as defined via the Relationship Designer

That concludes the overview of how to sort data in DocumentsCorePack with the Relationship Designer. It is also possible to sort grouped tables. For more information about how to group tables in DocumantsCorePack templates, please look at this blog article.

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

Was this helpful?

1 Yes  No
Related Articles
  • Debugging the Template Design Office Add-In 
  • Introducing the DocumentsCorePack Template Designer Office Add-In
  • Ensuring correct time zone display for DateTime fields
  • How to compare a date-fields with the current date 
  • Create a template for XML or plain text
  • E-Invoicing with DocumentsCorePack
Latest Articles
  • Recap: Nordic Summit 2025
  • The new Template Designer Office Add-In
  • Debugging the Template Design Office Add-In 
  • Updating Legacy SharePoint Connections 
  • What Happens After You Deploy AttachmentExtractor: Storage & Cost Savings in Dynamics 365
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
  • Important information for Dynamics 365 online customers using DocumentsCorePack and/or AttachmentExtractor
  • How to activate the DocumentsCorePack Connector for PowerApps & Microsoft Flow
  • How to insert Condition Fields in DocumentsCorePack Templates designer
  • How licenses are counted
Categories
  • *News and General Infos* 65
  • Webinars 46
  • Template Designer(DCP 197
  • DocumentsCorePack(DCP 260
  • TelephoneIntegration (TI 65
  • AttachmentExtractor (AE 75
  • 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.