• Release History
  • Documentation
  • Back to www.mscrm-addons.com
  • Release History
  • Documentation
  • Back to www.mscrm-addons.com
home/Knowledge Base/Template Designer(DCP)/How to create dates with ordinals with DocumentsCorePack field properties

How to create dates with ordinals with DocumentsCorePack field properties

636 views 0 Updated on July 30, 2024

Ordinal numbers represent position or rank in sequential order. The order may be of a size, importance, chronology, etc. These numbers may be written in English with numerals and letter suffixes: 1st, 2nd, 3rd, 4th, 5th, and so on.

Because ordinal numbers can be an essential part of documents, we have created the possibility to add ordinal numbers to templates. This step-by-step tutorial describes how to utilize an already prepared field function in your template(s) in order to place ordinals.

Please note: This article requires an already-created template. If you haven’t created a template before, have a look at this article before continuing. The attached Ordinal Numbers template document is a template that can be merged with an account (see Attached Files below). If you haven’t merged a template before, have a look at this article.

Step 1: Enable the field codes of your template

Open your template. If you do not see the field codes in this template, hit ALT + F9 on your keyboard to toggle the view. General information about field codes can be found here.

Step 2: Delete the current field used

Place your cursor in the <> and hit the delete field in our ribbon.

This is how the <> looks once it is extended:

The ordinal function
Figure 1: The ordinal function

Please note: The delimeter for methods (such as MOD) is dependent on the localization of your system.  For English systems, the delimeter is the comma (“,”) whereas for German systems, the delimeter is the semicolon (“;”).  As an example, the above function MOD(day;100) would be correct for German systems, but not English systems. Please modify the delimeters as needed.

Step 3: Copy the whole block and paste it into your template 

Copy the block from the actual attached document only.

Please note: Just copying and pasting the above text will not work.

Step 4: Insert a field of your choice

Replace the <> field with a field of your choice. You could add a data field or any other numeric field from the Template Designer TreeView. In this case, only the day is displayed.

Step 5: Open the field properties

Open the field properties with a right click and insert a ‘d‘ into the Format field.

The Field properties window.
Figure 2: Field properties

Please note: Sometimes, it can be necessary to add the month and year after the ordinal as well. In that case, simply add another date field behind the ordinal again and insert the required field properties. Learn how to insert fields here.  As the day is already represented as an ordinal, you only have to apply a format that displays the month and year (For example, MM, yyyy). Get more information on how to customize date and time formats here.

For further information about the function’s technical background, look at this article.

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

Attached Files
#
File Type
File Size
Download
1 .docx 31.92 KB Ordinal_numbers_template

Was this helpful?

Yes  No
Related Articles
  • 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
  • How to add content from SharePoint to a document
  • Using MS Word field codes in DocumentsCorePack templates
Leave A Comment Cancel reply

You must be logged in to post a comment.

Latest Articles
  • Recap: European Power Platform Conference 2025
  • Buried in Storage Fees? Here’s How to Cut Dynamics 365 Costs Fast
  • Why Document Generation Is Still the Most Broken Part of Your CRM Workflow
  • Recap: DynamicsMinds 2025
  • How to migrate One-Click-Actions (OCAs) between environments
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 licenses are counted
  • How to insert Condition Fields in DocumentsCorePack Templates designer
Categories
  • *News and General Infos* 64
  • Webinars 45
  • Template Designer(DCP 196
  • DocumentsCorePack(DCP 253
  • TelephoneIntegration (TI 65
  • AttachmentExtractor (AE 73
  • 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
  • © 2022 www.mscrm-addons.com. All Rights Reserved.