Monthly Archives: October 2015

AX 2012 R3: Error when installing Management Reporter using AX 2012 R3 CU8 or CU9 Installation Wizard

I’ve got some issues when I’m installing Management Reporter 2012 using Microsoft Dynamics AX 2012 R3 CU8 or CU9 Installation wizard.

Some of the errors I encountered are follows:

27/10/2015 2:38:46 PM – Extracting supporting files for database deployment…
27/10/2015 2:38:46 PM – Beginning database deployment…
27/10/2015 2:38:47 PM – Initializing deployment (Start)
27/10/2015 2:38:47 PM – Initializing deployment (Failed)
27/10/2015 2:38:47 PM – The database deployment failed. Additional information: Could not deploy package.
27/10/2015 2:38:59 PM – Microsoft.Dynamics.Performance.Deployment.Console.Core.DeploymentFailedException: An error occurred during database deployment. View the deployment log for more information.

The database deployment failed_ Additional information_Could not deploy package

Here’s what I did to solved the errors:

  1. I found that Management Reporter 2012 I’m trying to install is Version (2.1.8001.0) which is Management Reporter Cumulative Updates 8 or MR CU8.
  2. I downloaded latest Management Report 2012 Cumulative Updates and found MR CU13 and installed it using Management Reporter 2012 CU13 Installation wizard and successfully installed. See (Build Number).
  3. After installed my Management Reporter 2012 version is (2.1.13002.1) which is Cumulative Updates 13.


“This posting is provided “AS IS” with no warranties, and confers no rights.”

Best Regards,



AX 2012: Move file to another folder using WinAPI

static void ArisMoveFileUsingWinAPI(Args _args)

Filename fPath;
Filename fName;
Filename fType;

FileName DestinationPath = @’D:\DestinationFolder\’;
FileName sourcePath = @’D:\SourceFolder\test.csv’;;


[fPath, fName, fType] = fileNameSplit(#sourcePath);

WinAPI::moveFile(#sourcePath, strFmt(‘%1%2%3’, #destinationPath, fName, fType));

Box::info(‘File\s moved successfully!’);

AX 2012: Moving File to another Folder using System.IO.File

static void ArisMoveFileUsingSystemIOFile(Args _args)
Set permissionSet;
Filename fPath;
Filename fName;
Filename fType;

Filename sourcePath = @’D:\SourceFolder\test.csv’;
FileName DestinationPath = @’D:\DestinationFolder\’;


permissionSet = new Set(Types::Class);
permissionSet.add(new FileIOPermission(sourcePath,#io_write));
permissionSet.add(new InteropPermission(InteropKind::ClrInterop));


[fPath, fName, fType] = fileNameSplit(sourcePath);

System.IO.File::Move(sourcePath, strFmt(‘%1%2%3’, #destinationPath, fName, fType));


Box::info(‘File\s moved successfully!’);

AX 2012: Read CSV File using X++

public void readCsvFile(){
Io io;
container recordCon;
boolean firstLine = true;

FilePath processfilePath = @’C:\Temp\test.csv’;

io = new CommaTextIo(processfilePath, #IO_Read);

if(!io || io.status() != IO_Status::Ok){
throw error(“@SYS19358”);}

while (io.status() == IO_Status::Ok){
recordCon =;
if (recordCon){
if (firstLine){
firstLine = false;} // To skip headeror the firstline
// Do something here…}}}}

AX 2012: Posting Packing Slip using X++

static void JobPostPackingSlip(Args _args)
SalesFormLetter_PackingSlip     salesFormLetter_PackingSlip;

SalesTable                      salesTable;
CustPackingSlipJour             custPackingSlipJour;


salesTable = SalesTable::find(‘SO00000001’);
salesFormLetter_PackingSlip = SalesFormLetter::construct(DocumentStatus::PackingSlip);

if (CustPackingSlipJour::exist(‘SO00000001’))
info(strFmt(‘Sales Order successfully delivered!’));
info(strFmt(‘Sales Order failed to deliver!’));