When you upgrade to Microsoft Dynamics AX 2009 from an earlier version, you must make changes to the source code to ensure that the internal references comply with the new best practices. These changes include code changes, metadata changes, and table modifications, as described in the following sections.
For fields of the int64 data type assigned to a 32-bit integer value, the assigned-to variable must be rewritten as a variable of the same type, or explicitly cast to an int value. For example,
int RecId = table.RecId;
must be rewritten like this:
RecId RecId = table.RecId;
When a variable that derives from int64 is used as an index to an array, the code must be refactored to use a map. ...