Est. 1998 Intermediate

X++

The object-oriented, data-aware programming language behind Microsoft Dynamics 365 Finance and Operations - born in Denmark with the Axapta ERP system in 1998 and still powering enterprise business logic today.

Created by Damgaard Data (Erik Damgaard and team)

Paradigm Object-Oriented, Data-aware (integrated SQL)
Typing Static, Strong
First Appeared 1998
Latest Version Continuously updated with Dynamics 365 Finance and Operations

X++ is the proprietary, object-oriented programming language at the heart of Microsoft Dynamics 365 Finance and Operations (formerly Dynamics AX, originally Axapta). Its syntax looks familiar to anyone who knows C++, Java, or C# - but its defining trait is that SQL-style data access is built directly into the language. A select statement is not a string handed to a database driver; it is a first-class language construct, checked by the compiler against the application’s table definitions.

For nearly three decades, X++ has been the language in which one of the world’s major ERP platforms is written and customized, making it one of the most commercially significant languages that most programmers have never used.

History & Origins

Danish Roots: Damgaard Data

The story of X++ begins in Denmark. Brothers Preben and Erik Damgaard founded Damgaard Data in 1983 to build accounting software for personal computers. Their products Concorde (later C4) and especially Concorde XAL (1991) became widely used business software in Denmark and neighboring markets, and XAL came with its own built-in programming language.

By the mid-1990s the team recognized that XAL’s technology was reaching its limits. Rather than continue evolving the old language, they designed a new object-oriented language influenced by the C-family languages that were then reshaping the industry.

Axapta and the Birth of X++ (1998)

In March 1998, Damgaard Data released Axapta 1.0 in Denmark and the United States, in a sales and marketing partnership with IBM. Axapta shipped with an integrated development environment called MorphX and its new programming language, X++.

The pairing was central to Axapta’s pitch: the ERP system was not a black box. The complete application - forms, reports, tables, and business logic - was visible and modifiable in MorphX, and customers and partners customized it by writing X++ directly against the same object tree Damgaard’s own developers used.

From Navision to Microsoft (2000-2002)

IBM’s involvement was short-lived: reportedly around 1999, with the release of Axapta’s early updates, IBM returned its distribution rights to Damgaard. In 2000, Damgaard merged with fellow Danish ERP maker Navision Software to form NavisionDamgaard (later simply Navision A/S). Two years later, in July 2002, Microsoft acquired Navision for approximately $1.45 billion - one of the largest acquisitions in Microsoft’s history at that time. With it came two ERP product lines: Navision (which became Dynamics NAV, whose successor is today’s Business Central) and Axapta, which became Microsoft Dynamics AX.

The Dynamics AX Era (2006-2015)

Under Microsoft, the product was rebranded Dynamics AX 4.0 in 2006 and integrated progressively deeper into the Microsoft stack. Dynamics AX 2009 and Dynamics AX 2012 followed, each expanding the application and the language. AX 2012 marked a significant technical shift: X++ code for services and batch processing could be compiled to .NET Common Intermediate Language (CIL) rather than running only on the interpreted runtime that had powered the language since 1998.

The Cloud Rewrite (2016-Present)

In 2016 Microsoft released a fundamentally re-architected version - known during development as “AX 7” - with a browser-based HTML5 client, and rebranded it Dynamics 365 for Operations when Dynamics 365 became generally available in November of that year (renamed Dynamics 365 for Finance and Operations in July 2017, and later split into Dynamics 365 Finance and Dynamics 365 Supply Chain Management).

For X++ this was the largest change in the language’s history:

  • X++ now compiles fully to .NET CIL, the same output produced by the C# and Visual Basic compilers. According to Microsoft’s documentation, this makes X++ code run much faster than in AX 2012 and earlier, allows X++ applications to reference .NET assemblies efficiently, and lets many standard .NET tools operate on compiled X++.
  • Development moved from MorphX to Visual Studio, ending the 18-year run of Axapta’s original IDE.
  • Customization moved from overlayering to extensions, replacing direct modification of Microsoft’s source layers with a cleaner extension-class and event-handler model.

Since Microsoft’s “One Version” servicing model took effect in 2019, the platform and the X++ language have received continuous updates rather than discrete major versions.

Design Philosophy

X++ was designed as an application language for business software, and three ideas run through it:

  1. Data-awareness. ERP systems are database applications, so the language treats relational tables as first-class citizens. Table definitions live in the application model, and X++ includes keywords matching most of standard SQL, letting the compiler check queries against real schemas.
  2. Application-awareness. The language and its class libraries know about the surrounding application framework - forms, reports, number sequences, security, batch processing - so business logic plugs into ERP infrastructure instead of reinventing it.
  3. Customizability without forking. From Axapta’s original layer system (SYS, ISV, VAR, CUS, USR and others) to today’s extension model, the platform has always been built around the assumption that customers and partners will modify shipped code in a controlled, upgradable way.

Key Features

Integrated SQL

Data access is native syntax, not embedded strings:

CustTable custTable;

// Compiler-checked query against the CustTable schema
while select custTable
    order by AccountNum
    where custTable.Blocked == CustVendorBlocked::No
{
    info(strFmt("%1 - %2", custTable.AccountNum, custTable.name()));
}

Joins, aggregates, update_recordset, and insert_recordset are similarly built into the language, and queries run against the application’s table metadata with compile-time checking.

Familiar Object-Oriented Syntax

Classes, inheritance, and interfaces look much like Java or C#:

class Greeter
{
    str name;

    public void greet()
    {
        info(strFmt("Hello, %1!", this.name));
    }
}

X++ also provides garbage collection, exception handling with try/catch, reflection over classes and tables, and a set of collection classes - all documented characteristics of the language runtime.

The Extension Model (Chain of Command)

Modern X++ customization wraps standard methods without modifying Microsoft’s source code:

[ExtensionOf(classStr(SalesLineType))]
final class MySalesLineType_Extension
{
    public void insert()
    {
        // logic before the standard implementation
        next insert();
        // logic after the standard implementation
    }
}

The next keyword calls the next method in the chain, letting many independent extensions layer cleanly on the same standard method.

.NET Interoperability

Because X++ compiles to CIL, X++ code can reference classes from C# and other .NET assemblies, and application logic written in other managed languages can be integrated into X++ applications - a capability Microsoft highlights as a core benefit of the modern compiler.

Business-Oriented Details

The language carries ERP fingerprints throughout: dedicated primitive types such as date, utcdatetime, and timeofday; extended data types (EDTs) that add business meaning to primitives; label-based multilanguage strings; and a compiler that performs best-practice checks on top of ordinary syntax checking.

Development Environment

X++ has no standalone compiler or public runtime - it exists only inside its host platform, which is why there is no Docker image to try it in isolation. Today, development happens in Visual Studio with Microsoft’s Dynamics 365 development tools, against a local or cloud-hosted development environment. Source is managed as metadata-plus-code “models” and packaged for deployment to Microsoft-managed cloud environments.

For its first 18 years, however, the developer experience was MorphX: an IDE embedded in the ERP client itself, where developers browsed the entire application in the Application Object Tree (AOT) and edited code, forms, and tables in place - an unusually transparent architecture for commercial enterprise software of its era.

Current Relevance

X++ occupies a similar niche to SAP’s ABAP: a proprietary language invisible to most of the software industry yet critical to the enterprises that run on it. Dynamics 365 Finance and Supply Chain Management is one of the major cloud ERP platforms, and every implementation of it involves X++ - Microsoft’s own application code, ISV add-ons distributed through AppSource, and customer-specific extensions built by a global ecosystem of implementation partners.

The language itself remains under active development. Microsoft ships regular platform updates under the One Version model, maintains an extensive X++ language reference on Microsoft Learn, and continues to evolve the compiler and its .NET integration. X++ developer skills remain in steady demand wherever Dynamics implementations run.

Why It Matters

X++ is a case study in a road less traveled: instead of building an ERP system in a general-purpose language, Damgaard Data built a language for an ERP system. The result demonstrated ideas that remain interesting today:

  • Language-level SQL integration, decades before LINQ popularized compiler-checked queries in mainstream languages
  • A fully inspectable, modifiable business application, where the vendor’s source code was part of the product
  • Layered and later extension-based customization, tackling the hard problem of letting thousands of parties safely modify the same codebase
  • A successful migration story, moving a proprietary interpreted language onto the .NET CIL runtime without abandoning its ecosystem

From a Danish accounting-software company to one of Microsoft’s flagship cloud businesses, X++ has quietly processed an enormous share of the world’s manufacturing, distribution, and financial transactions for more than 25 years - a reminder that some of the most consequential programming languages live entirely inside the systems they were born to build.

Timeline

1998
Axapta 1.0 released in March by Danish company Damgaard Data in partnership with IBM, introducing the X++ language and MorphX development environment
2000
Damgaard Data merges with Navision Software to form NavisionDamgaard; Axapta 2.5 released
2002
Microsoft acquires Navision in July for approximately $1.45 billion, bringing Axapta and X++ into the Microsoft fold; Axapta 3.0 released
2006
Product rebranded as Microsoft Dynamics AX 4.0, with deeper integration into the Microsoft technology stack
2008
Microsoft Dynamics AX 2009 released
2011
Dynamics AX 2012 released; X++ code for services and batch processing can now be compiled to .NET CIL
2016
The new Dynamics AX ('AX 7') launches with a browser-based HTML5 client; X++ now compiles fully to .NET CIL and development moves from MorphX to Visual Studio; rebranded Dynamics 365 for Operations when Dynamics 365 became generally available in November
2017
Product renamed Dynamics 365 for Finance and Operations in July; the extension model begins replacing the classic overlayering approach to customization
2019
Microsoft's 'One Version' continuous-update model takes effect, delivering regular platform and X++ compiler updates to all customers

Notable Uses & Legacy

Microsoft Dynamics 365 Finance

The entire application layer of Microsoft's cloud ERP for financial management - general ledger, accounts payable/receivable, budgeting, and tax - is written in X++.

Dynamics 365 Supply Chain Management

Manufacturing, warehouse management, inventory, and logistics business logic implemented in X++ and run on Microsoft's cloud infrastructure.

ISV vertical solutions

Independent software vendors build industry-specific add-ons (retail, construction, food processing, equipment rental) as X++ extension packages distributed through Microsoft AppSource.

Partner and customer customizations

Thousands of implementation partners and in-house teams worldwide extend standard ERP behavior with X++ extension classes, event handlers, and batch jobs.

Legacy Dynamics AX deployments

On-premises Dynamics AX 2009 and AX 2012 systems still run customized X++ codebases at enterprises in manufacturing, distribution, and retail.

Language Influence

Influenced By

Influenced

None widely known

Running Today

Run examples using the official Docker image:

docker pull
Last updated: