Exporting Project Definitions

I concocted the following bit of code to automate the task of exporting project definitions to XPO files. It is a simple bit of code that allows the user to dump the project definition files to a specified folder.

Continue reading

Share/Bookmark
Posted in AX 2009, AX 2012, AX 4.0, Microsoft Dynamics AX | Tagged , , , , | Comments Off

Parsing Date Strings

Dynamics AX provides functions for parsing date strings into a date object but they are limited at best.

The following static method uses the .Net date parsing functionality to create a X++ date object from any valid date string without knowing the year, month, and day sequence or anything else about it for that matter.

It also allows you to specify the value that is returned in case of an invalid string being passed.

Continue reading

Posted in AX 2009, AX 2012, AX 4.0, Microsoft Dynamics AX | Tagged , , , | Comments Off

CLR Array to AX List

If you use any amount of CLRInterop programming in Dynamics AX you have probably at some point or another needed to use X++ code to interact with an array object passed back from a bit of CLR code.

I created the following static class to ease the process of converting a CLRArray object into a X++ style list object.

Continue reading

Posted in AX 2009, AX 2012, AX 4.0, Microsoft Dynamics AX | Tagged , , , , | 1 Comment

Automatic Class Pack/Unpack

A common task associated with creating objects in Dynamics AX is giving them the ability to be packed into a container for storage as a SysLastValue entry.

The common methodology used for this is to declare a version and a list macro in the class declaration and to add the standard Pack and Unpack methods to your class. The problem with this standard methodology is that you must constantly update the version and list macros to add new parameters that you want to store. You then have to deal with the various issues related to tracking all of these version changes, and unpacking them accordingly.

I have developed a version independent method for automatically generating the packed class that makes code maintenance simplistic. The unpacking of the class is just as simple and isn’t subject to the issues associated with tracking packed class versions.

Posted in AX 2009, AX 4.0, Microsoft Dynamics AX | Tagged , , , | 1 Comment

Welcome!

Welcome to my blog. Please check back often as I will be adding more content as soon as I get the site completely up and running.

Posted in Uncategorized | Comments Off