- Blog


This blog is deprecated since July 2020.The articles below are no longer maintained and might contain outdated information. 
You can find the most acutal and relevenat information in our Knowledge Base at Blog


Hello and welcome to our blog! What can we do for you? Are you looking for further technical information or step-by-step instructions to our products? Or would you like to read the latest news on mscrm-addons? Please feel free to browse our blog for detailed information and to share our posts!

Advanced [Print in Word]-Button Configuration

Basically, the default [Print in Word]-button contains JavaScript code in the background.

If you are familiar with CRM and JavaScript you can add your own custom buttons to increase the usability of your CRM system. If you are using Dynamics 365, please also have a look at this article here

e.g., you can predefine a template that should be always used to perform the merge. 

You can modify the JavaScript code, so that - based on certain criteria - a template is automatically selected without user interaction.

The following article contains a description of how to change, modify and extend this feature.

First of all, to get access to the Advanced Button Configuration, you have to start the DocumentsCorePack Server Configuration Tool.

On the bottom of the General-tab, you will find the [Advanced Button Configuration]-button.

Figure 1: DocumentsCorePack Server Config General tab

When clicking on this button, the Advanced Button Configuration-dialog appears. 

Figure 2: Advanced Button Configuration

In this dialog, you can select the entity that you want to manage.
E.g. Already existing custom [Print in Word]-buttons will be listed and can be deleted.

If you press the [Add]-button, the following Edit button-dialog apprears.

Figure 3: Edit Button dialog

The Add-functionality gives you the possibility to define a custom name for your button and you can select
the JavaScript function that should be executed if you hit the generated button.

The DocumentsCorePack Configuration Tool already includes a few Javascript-templates you can use to get started.

The following functions are predefined:

- CustomPrintInwordActionAcount

- PrintQuoteWithSpecificTemplate

With a click on the [Modify JavaScript]-button the JavaScript webresource (ptm_dcp_custombuttonactions.js) is opened in a new CRM window. 

The CRM window allows you to see the detailed JavaScript code by clicking on the [Text-Editor]-button.

Figure 4: JavaScript webresource-window

The prefabricated JavaScript contains a comprehensive in-line documentation.

Figure 5: Prefabricated JavaScript

Another example that is part of this webresource can also be found here with some additional information. 

That’s it! We appreciate your feedback! Please share your thoughts by sending an email to

Comments are closed.