Search code examples
.netaxaptax++proxy-classesdynamics-ax-2012

How to join AX tables using .net interop?


I am trying to create a utility for AX 2012 in visual studio using .net interop to X++ and proxy classes, I've added necessary tables in my project, I can access tables individually and can loop them through .next() method, but I want to join these tables so I can get my desired results (I want to display a grid with item id, name alias, color, size information).

I am unable to figure out how to join InventTable, InventDim andInventDimCombination` for this purpose. Can you guys please tell me how can I join AOT tables without having to use traditional .net business connector methods in visual studio?


Solution

  • Upgrade to AX 2012 R2. Then use LINQ. A code example.

    Update:

    If not possible, then create an AX query, either in AX or programmaticly from .Net. Then use the query the get the AX records. A working example.

    Or use the AX 2012 AIF Query AIF Web Service.