01 November 2015

How to get the AX info infolog value in ax 2009 / 2012 Exception handling example.

static void exceptionHandling(Args _args)
{
CustTable cust;
int i;
CustProjErrorStack custProjErrorStack;
;

try{
while select cust where cust.ABC_Approval != noyes::Yes
{
if(CustTable::find(cust.AccountNum))
{
}
}
}
catch(exception::Error)
{

for (i=1; i<=infolog.line(); i++)

{

custProjErrorStack.ErrorType = ErrorType::Error;
custProjErrorStack.Message = infolog.text(i);
custProjErrorStack.insert();

}

}
}

2 comments:

  1. Nice and Useful Information, It is Very Useful for me and Thanks.This is also Useful who wants
    Microsoft Dynamics AX Training | Microsoft Dynamics CRM Online Training

    ReplyDelete

Give me the commetns and solutions

Ledger Voucher creation Framework and x++ code to create ledger voucher

 Please click her for MS reference file Below is the out of the box example reference and code. SalesInvoiceJournalPostSubBill_Extension-...