• About
  • D365 Consulting
  • Technical Services
  • D365 Integration
  • D365 Upgrade
  • Blog
  • Contact
  • About
  • D365 Consulting
  • Technical Services
  • D365 Integration
  • D365 Upgrade
  • Blog
  • Contact
Category:

AX2012

Browse: Home / Blog / AX2012
07Apr2016

AIF Error – ContractFilter mismatch at the EndpointDispatcher

by Wolftek in AIF, AX2012, Integration, Services
Tags: AIF, AX2012 R3, Integration

If you’re seeing this error when consuming an AIF service, the reason may be that changes were made to the service object in the AOT, without regenerating the incremental CIL and reactivating the inbound port.

In our case, one of the developers changed the namespace of the service in the AOT from the default ‘http://tempuri.org’ to ‘http://schemas.microsoft.com/dynamics/2011/01/services.’ The service was refreshed in the ‘Services’ form, and the inbound test file was updated with the correct namespace. However, since the Inbound Port wasn’t reactivated, the service endpoint (in our case the client used a File System Adapter), was still deployed with the old namespace, resulting in the error below. Reactivating the port (and Incremental CIL) updates the endpoint with the proper namespace and resolves the issue.

The request failed with the following error: The message with Action ‘http://schemas.microsoft.com/dynamics/2008/01/services/<Service>/<Action> cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the receiver. Check that sender and receiver have the same contract and the same binding (including security requirements, e.g. Message, Transport, None).
View the exception log for more details.

27Jan2016

DIXF Crash – Decimals in CSV Source files

by Wolftek in AX2012, DIXF
Tags: AX2012 R3, DIXF
Wolftek.Dynamics.AX

We have noted an issue with the DIXF *.CSV source file import, where the presence of decimal values causes the DIXF service to crash. The issue occurs with standard AX entities, in our case the SalesLines entity. The error details in the Event Log are quite obscure, rendering the fix unintuitive.

Yet, the solution is very simple. To get around the error, you can change the CSV file extension association from Excel to Notepad. As can be seen below, the file type in the Windows Explorer changed from ‘Microsoft Excel Comma Separated Values File’ to a ‘CSV File.’ As a result, the CSV files, containing decimal values, import without an issue.

Before:

After:

02Sep2015

DIXF ODBC Source Automation – AX2012 R3

by Wolftek in AX2012
Tags: AX2012 R3, DIXF, Integration

 

The AX2012 R3 version of DIXF has introduced automation for file based integrations. It is now possible to configure a periodic processing to monitor a directory for incoming files and to import them into the DIXF staging tables. Furthermore, the ‘Execute Target Step’ setting on the definition group execution, allows the source-to-staging process to also execute the staging-to-target logic. This turns DIXF into a rounded solution, which supports full end-to-end source to target scenarios out of the box. Add to all this the excellent staging and tracking capabilities, and this turns DIXF into an excellent candidate for integrations, rivaling in many respects the AIF framework.

The automation functionality described above had to be custom coded in the previous versions of AX – see the following blog for example.

What is still missing from this version of DIXF, however, is the automation capabilities for other sources, such as ODBC. That is, if you’re reading the source data from SQL, for example, you’re still unable to execute the import steps in a Periodic batch job.

If you do need to implement such automation, have a look at the following script for inspiration.

static void DIXF_Automation_ODBC(Args _args)

{

    DMFDefinitionGroupEntity entity = DMFDefinitionGroupEntity::find(‘<Processing Group>’, ‘<Entity>’);

    DMFStagingWriterContract contract = new DMFStagingWriterContract();

    DMFStagingWriterService service;

    contract.parmExecutionID(‘wolftek1’); //todo: get from num seq

    contract.parmDefinationGroupName(Entity.DefinitionGroup);

    contract.parmEntityNameList(Entity.Entity);

    contract.parmFilePath(entity.QueryForODBC);

    contract.parmRunInBatch(true);

    contract.parmExecuteTargetStep(true);

    service = new DMFStagingWriterService();

    service.executeService(contract);

}

28Aug2015

AIF Error – Return type void is not supported

by Wolftek in AIF
Tags: Integration

Wanted to mention this briefly, in hope that it may save someone some headaches.

In case you are seeing the following error in the AIF Exception log: “Return type void is not supported,” followed by “Unsupported type,” there may be a compilation issue with one of the axBc classes of the service.

13Jul2015

Change the Model Manifest’s Deployment Layer

by Wolftek in AX2012, Deployment
Tags: Manifest, Model

As you may know the AX utilities – AXUtil and PowerShell – do not support changing the destination layer in the model manifest. The model, by default, gets imported into the same layer, from which it was exported. For reference refer to: https://technet.microsoft.com/en-us/library/hh433512.aspx.

This said, if you need to import the model into a different layer, than the one from which it was exported, you can employ the following procedure.

Open the binary *.axmodel file for editing in a text editor, in order to modify its manifest. The caveat here is that Notepad, for instance, cannot be used, as it can’t properly display/save the binary information. One editor that we like utilizing is SciTE, which can be downloaded here: http://www.scintilla.org/SciTEDownload.html.

Once opened in the editor, change the model’s manifest, to specify an alternate deployment layer and save the file.

 

29May2015

SysOperation UI Builder – Product Category Hierarchy

by Wolftek in AX2012, Services
Tags: SysOperation

We had a requirement to provide the user with a selection of the Product Categories, in the service’s dialog. Here is a quick example of how the SysOperation framework UIBuilder classes can be leveraged to display intricate lookups.

Contract with the linked UIBuilder

The hierarchy and the category are the RefRecId’s

Without the necessary changes in the UIBuilder, the dialog displays a simple drop down, listing all the available categories in the system:

Register the overridden lookupReference() method for the Category field:

The Category dialog field now displays a nicely formatted lookup of the category structure for the selected hierarchy:

17Mar2015

TFS – Corrupted XPO in Repository

by Wolftek in AX2012, TFS,
Tags: Build, TFS

We have experienced situations when a developer attempts to check out an object in AOT, and while the object gets properly checked out in TFS, AX doesn’t quite ‘check it out.’ This is manifested by the fact that while the object gets the familiar blue text highlight in the AOT, indicating that it is checked out to the developer, editing of the object, is nonetheless, disabled.

Attempting to Get the latest version of the object, may also result in an error to the effect that the “Access to the path <Local Repository\object.xpo> is denied…Synchronization failed.”

This is likely an indication that the object’s XPO, in the local repository, got corrupted.


One way to resolve this, is to delete the XPO from the local repository; and Synchronize the version control.

17Mar2015

Scheduling Engine – CLR Error

by Wolftek in AX2012, Production
Tags: AX2012, Production

There is an intriguing error in the scheduling engine – “A CLR error occurred while invoking the scheduling engine.“


The infolog message is not very descriptive…at first sight. However, if you focus on the message text above the error, you will see the details of the error in the bottom pane:


That may work for you, but in order to enhance the user experience, you may want to make a small change to the ProdUpdScheduling class, and handle the CLR error elegantly to show the error to the user.



14Jan2015

Script Record – Record Info

by Wolftek in AX2012, Configuration

This one may sound trivial, but we get asked about it quite a bit. If you are looking to have the ‘Script’ option available in the Record Info form, the ‘Test framework’ configuration key needs to be enabled.

script - record info

 

script - config key

08Jan2014

CIL Build – VS Project AOT reference

by Wolftek in AX2012, Deployment
Tags: AX2012, Build, Deployment

We have encountered a CIL compilation issue for a custom class which referenced a custom VS project in the AOT.

The errors gave no indication as to the cause and looked as follows:

Cannot create a record in Compiler information (TmpCompilerOutput). Path: Classes<class><method>, Warning: No proxy found. Type FileIOPermission found on the stack. This code in Class: <class>, Method: <method>.

The record already exists.

Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

The interesting thing is, that the class in question compiled fine. However, when we looked at it in the AOT, right after the CIL generation failed, and hovered over the method’s signature line, we saw a context error message stating: CIL generation: Error: .NET Cast Type Name not found. Type System.String found on the stack. This code in Class/Table: <Class>, Method: <method> may not work in CIL run time.

In order to resolve we copied the Microsoft.Dynamics.AX.Xpp.Support.dll assembly from the Server/Bin to Client/Bin, which produced a clean CIL compilation.

  • 1
  • 2
  • Next »

Recent Posts

  • Wolftek - D365FO Integration
    Power Platform connections to D365 and AAD Tokens

    In this short post we wanted to offer some clarifications…

  • Electronic Reporting
    Electronic Reporting – Positive Pay in Text Format

    Introduction   In this blog we demonstrate the use of…

  • Power Apps – Code Reuse

    Yes, we know. No self-respecting D365 developer can stand the…

  • Power Apps – The Three Flavors of D365 Connections

    There are many different ways to connect Power Apps to…

  • AIF Error – ContractFilter mismatch at the EndpointDispatcher

    If you’re seeing this error when consuming an AIF service,…

Categories

  • AIF
  • AIF
  • AX2012
  • Configuration
  • Deployment
  • DIXF
  • Dynamics 365 F&O
  • Electronic Reporting
  • Integration
  • Integration
  • Power Apps
  • Production
  • Services
  • SSRS
  • TFS
  • Uncategorized
  • Upgrade

Add some widgets to this area!

  • About
  • D365 Consulting
  • Technical Services
  • D365 Integration
  • D365 Upgrade
  • Blog
  • Contact

© 2022 Wolftek, Inc.