September 17, 2014

Finding the current accounting currency code through X++ code

Hi Guys ,

Just sharing small trick to pull the current accounting currency through X++ code

here are three way to pull current currency,
1. currCode = Ledger::accountingCurrency(CompanyInfo::current());
2. currCode = Ledger::accountingCurrency(CompanyInfo::Find().recid);
3. currCode = CompanyInfo::standardCurrency();


September 08, 2014

Error while compiling the project after import

Error: After import a new project from another server, while compiling system gives below error message:

AX1004: Reference System.Core, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089 was not a valid model assembly.

Warning Message:

MSB3644: The reference assemblies for framework ".NETFramework,Version=v4.0" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or
Line: 983


Possible Reason:

It might be your .net version.


Install .net version 4 from below link

After installing this update this error should not come.