Today I found an exciting new feature in Dynamics AX 2009: cross company support in forms, reports, queries and X++.
Yes, and it really is what you think: you can display records from different companies in a single form (or report). Yeah !
For a form, you just have to set the property AllowCrossCompany to Yes in the form's query and add a field that displays the company's ID to the forms's grid. That's it. Easy as that!
In X++, there is a new keyword crossCompany you can use in a select statement. Additionally, you can add a container with all the company ID's you want to include in your select statement.
So, your select statement could look like that:
while select salestable crossCompany : [dmo, cos]
... do something ...
Now, that's really a huge step forward from the good old changeCompany function.
Development tutorial: SysExtension framework in factory methods where the constructor requires one or more arguments
vor 1 Woche