This article guides you through the process of setting up a contract between Microsoft Dynamics 365 Customer Engagement and Microsoft Dynamics 365 Finance & Operations. To this end, follow the step-by-step guide provided below.


Note


A printing contract is the established relationship between the executing party in Microsoft Dynamics 365 Customer Engagement (the ex button or the directsubmit button) and a certain report within Microsoft Dynamics 365 Finance & Operations.


Before you start to set up a printing contract, you are to create a connection between Microsoft Dynamics 365 Customer Engagement and Microsoft Dynamics 365 Finance & Operations. For more details, see the How to connect to Dynamics 365CE from Dynamics 365FO article.


Create a class report


Start by creating a class report which fetches the CRM data in the Microsoft Dynamics 365 Finance & Operations.


1. In Microsoft Dynamics 365 Finance & Operations, on the navigation pane under Modules, click Lasernet, and then under Common, click Reports.


2. On the Reports page, click the New button.


3. Within a new record which appears in the list, select Class as a report origin, enter a report name, and then select OData as a report design name.



4. Once you are done, ODATA REPORT WIZARD opens to help you to build a report core structure. To this end, follow each step of the wizard defining the information you need. Thus, on step 2, select a connection name to define the OData connection to the Microsoft Dynamics 365 Customer Engagement environment.



5. On step 3, define tables from which data is to be fetched.


It is possible to combine the data from both Microsoft Dynamics 365 Customer Engagement and Microsoft Dynamics 365 Finance & Operations in the same query/report.


Below you can find a list of options related to reports using the class as an origin:


  • Run report from Microsoft Dynamics 365 Finance & Operations and only use data from Microsoft Dynamics 365 Customer Engagement
  • Run report from Microsoft Dynamics 365 Customer Engagement and only use data from Microsoft Dynamics 365 Customer Engagement
  • Run report from Microsoft Dynamics 365 Finance & Operations and use data from both Microsoft Dynamics 365 Finance & Operations and Microsoft Dynamics 365 Customer Engagement
  • Run report from Microsoft Dynamics 365 Customer Engagement and use data from both Microsoft Dynamics 365 Finance & Operations and Microsoft Dynamics 365 Customer Engagement


Most of the features in Lasernet AX Connector for Microsoft Dynamics 365 Finance & Operations are supported by data/fields from Microsoft Dynamics 365 Customer Engagement and this data can be added either via the Query Wizard or via the expression.


The report you have created is to be further executed. Running the report is possible when OData Dialogs or OData Direct Submit is correspondingly configured. You can trigger this report using Lasernet Connector for Microsoft Dynamics 365 Customer Engagement.


Configuring OData Dialogs


As prerequisites to the configuration process, OData Dialogs shall be added to the flyout menu. For more details, see the How to configure the Lasernet Connector within CE | Creating a flyout menu article. Afterwards, follow the step-by-step instructions provided below.


1. In Microsoft Dynamics 365 Customer Engagement, on the Sales menu, click the down-pointed arrow to show the navigation menu flyout. Under the Settings flyout, locate the Lasernet list, and then click OData Dialogs.


2. As a result, the Acive Lasernet OData Dialogs page opens.


3. Click the New button to add a new OData Dialogs connection and define when to trigger a report in Microsoft Dynamics 365 Customer Engagement.


Below is an example of the OData Dialogs configuration.



As a result, you have created an action which allows executing a report in Microsoft Dynamics 365 Finance & Operations. When a corresponding button is clicked in Microsoft Dynamics 365 Customer Engagement, this action is then applied, and thus, the report is executed.


So, now it is time to verify that the required settings are defined in Microsoft Dynamics 365 Finance & Operations, and it properly acts when a report is triggered in Lasernet Connector for Microsoft Dynamics 365 Customer Engagement.


Entity reports


Switch back to Microsoft Dynamics 365 Finance & Operations and create a printing report between Microsoft Dynamics 365 Finance & Operations and Microsoft Dynamics 365 Customer Engagement. To this end, follow the steps listed below.


1. In Microsoft Dynamics 365 Finance & Operations, on the navigation pane under Modules, click Lasernet, and then under Dynamics 365CE, click Entity reports.


2. Click the New button.


3. Specify a report name. Put both the Active and Recording toggle buttons to Yes status. Once you are done, click the Save button.



Note


The Recording status allows to log your next actions and, thus, set up a rule which you can use next time performing the same actions.


4. Switch back to Microsoft Dynamics 365 Customer Engagement. On the Sales menu, click the down-pointed arrow to show the navigation menu flyout. Under the Settings flyout, locate the Collateral list, and then click Quotes. In the Quotes list, click the required quote item to open it.


5. On the quote page displayed, click Lasernet, and then click the button which allows opening a form connected to Microsoft Dynamics 365 Finance & Operations. On the screenshot below, it is the Dialog(Group) button. You give a name to this button while configuring OData Dialogs by specifying a value in the Button text text box on the OData Dialogs configuration page.



6. In the window displayed, click the Refresh button. As a result, a form connected to Microsoft Dynamics 365 Finance & Operations opens.


As you can see in the message, the requested parameters have been recorded.



7. Switch back to Microsoft Dynamics 365 Finance & Operations, the Entity report page, and click the Refresh button.


As you can see on the screenshot below, the Criteria list is populated with records which have been sent from Microsoft Dynamics 365 Customer Engagement to Microsoft Dynamics 365 Finance & Operations.



8. In the Criteria list, locate the PrimaryEntityType criterion denoting a quote, and select the Check check box for it.



By selecting the primary entity type and specifying it as a quote, you define that the report you are currently creating is to run every time when a quote is sent. To avoid sending all the quotes available in the system, you shall apply a filter by defining a report range.


Report ranges


1. In Microsoft Dynamics 365 Finance & Operations, on the page of the entity report you create, click Default ranges.


2. On the Inquiry pane that appears, click the New button.


3. Specify a data source as well as a field name for the range.


4. Once you are done, click the settings button to specify the range itself.



5. On the Range pane that appears, first, click Delete all, and then click the plus sign button.


6. On the Segment pane that appears, specify the required value.



7. Once you are done, click OK on each pane. Before saving the changes you have made, switch the Recording toggle button to the No status, and then click Save.


Thus, every time you click Dialog(Group) under Lasernet in Microsoft Dynamics 365 Customer Engagement, the report with the parameter you have specified is run.