Showing posts with label AIF. Show all posts
Showing posts with label AIF. Show all posts

Tuesday, 12 May 2015

Update DefaultDimension through Connector for Microsoft Dynamics

We had interesting problem with updating of some data entities' DefaultDimension. Normally for update Connector asks for original data (performs find operation), uses those data as default data and overwrite only those data where values are provided from 3rd party system. It means that any of data defaulted in AX, when create operation was performed, is not overwritten by empty values.

Wednesday, 11 February 2015

Default Dimensions seem to be just single field of type long instead of dictionary entity in Connector and in VS

There is probably incorrect Extended Data Type on DefaultDimension field in table. There should be DimensionDefault. If there is another one (e.g. RefRecId) then correct code is not generated by AIF wizard to Ax<Table> class and to Data object class.

If you can change EDT then do it and regenerate AxBC classes and data objects.

If you can’t change EDT or regeneration did not help then update classes manually:

Ax<Table> class: 
change EDT in parmDefaultDimension method to "DimensionDefault"

<Service>_<Table> class:

add method createDefaultDimension

public AifDimensionAttributeValueSet createDefaultDimension()
{
    return this.get_NewContainer(#DefaultDimension);
}

change method parmDefaultDimension

public AifDimensionAttributeValueSet parmDefaultDimension(AifDimensionAttributeValueSet _value = null)
{
    if (!prmisDefault(_value))
    {
        this.set_Container(#DefaultDimension, _value);
    }
    return this.get_Container(#DefaultDimension);
}

Friday, 31 October 2014

AX 2012 Integrations - using Microsoft Connector for Dynamics

Although MS Connector for Dynamics' purpose is to connect and integrate products from MS Dynamics family it is possible to use it to integrate AX and 3rd party's systems.

We are currently using Connector this way. I faced several problems through AIF services development to be able to use them with Connector. Here are some points.