The MorphX Development Environment and Tools

  • 8/11/2014


For a fully customizable overview of the elements, you can use projects. In a project, you can group and structure elements according to your preference. A project is a powerful alternative to the AOT because you can collect all the elements needed for a feature in one project.

Creating a project

You open projects from the AOT by clicking the Project icon on the toolbar. Figure 2-6 shows the Projects window and its Private and Shared projects nodes.


FIGURE 2-6 The Projects window, showing the list of shared projects.

Except for its structure, a project generally behaves like the AOT. Every element in a project is also present in the AOT.

When you create a new project, you must decide whether it should be private or shared among all developers. You can’t set access requirements on shared projects. You can make a shared project private (and a private project shared) by dragging it from the shared category into the private category.

You can specify a startup project in the Options form. If specified, the chosen project automatically opens when AX 2012 is started.

Automatically generating a project

Projects can be automatically generated in several ways—from using group masks to customizing project types—to make working with them easier. The following sections outline the various ways to generate projects automatically.

Group masks

Groups are folders in a project. When you create a group, you can have its contents be automatically generated by setting the ProjectGroupType property (All is an option) and providing a regular expression as the value of the GroupMask property. The contents of the group are created automatically and are kept up to date as elements are created, deleted, and renamed. Using group masks ensures that your project is always current, even when elements are created directly in the AOT.

Figure 2-7 shows the ProjectGroupType property set to Classes and the GroupMask property set to ReleaseUpdate on a project group. All classes with names containing ReleaseUpdate (the prefix for data upgrade scripts) will be included in the project group.


FIGURE 2-7 Property sheet specifying settings for ProjectGroupType and GroupMask.

Figure 2-8 shows the resulting project when the settings from Figure 2-7 are used.


FIGURE 2-8 Project created by using a group mask.


You can also generate a project based on a filter. Because all elements in the AOT persist in a database format, you can use a query to filter elements and have the results presented in a project. You create a project filter by clicking Filter on the project’s toolbar. Depending on the complexity of the query, a project can be generated instantly or it might take several minutes.

With filters, you can create projects containing elements that meet the following criteria:

  • Elements created or modified within the last month
  • Elements created or modified by a named user
  • Elements from a particular layer

Development tools

Several development tools, such as the Wizard Wizard, produce projects containing elements that the wizard creates. The result of running the Wizard Wizard is a new project that includes a form, a class, and a menu item—all the elements that make up the newly created wizard.

You can also use several other wizards, such as the AIF Document Service Wizard and the Class Wizard, to create projects. To access these wizards, on the Tools menu, click Wizards.

Layer comparison

You can compare the elements in one layer with the elements in another layer, which is called the reference layer. If an element exists in both layers and the definitions of the element are different, or if the element doesn’t exist in the reference layer, the element is added to the resulting project. To compare layers, click Tools > Code Upgrade > Compare Layers.

Upgrade projects

When you upgrade from one version of Microsoft Dynamics AX to another or install a new service pack, you need to deal with any new elements that have been introduced and existing elements that have been modified. These changes might conflict with customizations you’ve implemented in a higher layer.

The Create Upgrade Project feature makes a three-way comparison to establish whether an element has any upgrade conflicts. It compares the original version with both the customized version and the updated version. If a conflict is detected, the element is added to the project.

The resulting project provides a list of elements to update based on upgrade conflicts between versions. You can use the Compare tool, described later in this chapter, to see the conflicts in each element. Together, these features provide a cost-effective toolbox to use when upgrading. For more information about code upgrade, see “Microsoft Dynamics AX 2012 White Papers: Code Upgrade” at

To create an upgrade project, click Tools > Code Upgrade > Detect Code Upgrade Conflicts.

Project types

When you create a new project, you can specify a project type. So far, this chapter has discussed standard projects. The Test project, used to group a set of classes for unit testing, is another specialized project type provided in AX 2012.

You can create a custom specialized project by creating a new class that extends the ProjectNode class. With a specialized project, you can control the structure, icons, and actions available to the project.

Related resources

There are currently no related titles.