Skip to main content

Posts

Showing posts with the label AX 2012

Calling the LedgerGeneralJournal Service in AX 2012

GeneralJournalServiceClient  client =  new   GeneralJournalServiceClient (); CallContext  context =  new   CallContext (); context.Company =   "ceu" ; AxdLedgerGeneralJournal  journal =  new   AxdLedgerGeneralJournal (); AxdEntity_LedgerJournalTable  journalHeader =  new   AxdEntity_LedgerJournalTable (); journalHeader.JournalName =  "GenJrn" ; AxdEntity_LedgerJournalTrans  journalLine =  new   AxdEntity_LedgerJournalTrans (); journalLine.AccountType =  AxdEnum_LedgerJournalACType .Ledger; journalLine.AccountTypeSpecified =  true ; journalLine.Company =  "ceu" ; AxdType_MultiTypeAccount  account =  new   AxdType_MultiTypeAccount (); account.Account =  "131100" ; account.DisplayValue =  "131100-OU_2311-OU_3569-Customer visit" ; AxdType_DimensionAttributeValue  dimValue1 =  new   AxdType_DimensionAttributeValue...

Dynamics AX 2012 Reporting: How to specify new design for Sales order confirmation

Sales order confirmation report is one of the special reports which are manage by print management. When we create new design in Visual Studio for out Sales order confirmation report and we want to use it it is not enough to change the code. Even those we will change the code in class AOT\Class\SalesConfirmationController method main from: controller.initArgs(_args,ssrsReportStr(SalesConfirm,Report) to controller.initArgs(_args,ssrsReportStr(SalesConfirm,Report_NewDesign) that will not be picked up and sales confirmation will be still printed in old design. To change the design you need to: If you go to Account receivable > Setup > Forms > Form setup Click on button Print management You will see that by default report format is set up to: SalesConfirm.Report If you want to use every time your new design then you can select for Report format your desire design. If your desire format does not appear in drop down list you will need to edit method popula...

Importing Products into AX 2012

EcoResProductServiceClient service = new EcoResProductServiceClient();             CallContext ctx = new CallContext();             ctx.Company = "ceu";             AxdEcoResProduct axdProduct = new AxdEcoResProduct();                         //first, create a distinct product             AxdEntity_Product_EcoResDistinctProduct distinctProduct = new AxdEntity_Product_EcoResDistinctProduct();             distinctProduct.DisplayProductNumber = "Bulb60W";             distinctProduct.ProductType = AxdEnum_EcoResProductType.Item;     ...

Importing Customers, Vendors and Products in AX 2012

This calls the vendor service: using System; using System.Collections.Generic; using System.Linq; using System.Text; using ConsoleApplication9.Vendors; namespace ConsoleApplication9 {     class Program     {         static void Main(string[] args)         {             VendTableServiceClient proxy = new VendTableServiceClient();             CallContext context = new CallContext();            context.Company = "ceu";  //New class that replaces AX endpoints.  It makes it obvious which company you are importing data into.  I love this class!!              AxdVendTable vendor = new AxdVendTable();      ...