This blog is for Dynamics AX (AXAPTA) Developers,this will help you for your development issues. This site contains some Microsoft Dynamics AX X++ Codes for use in your day to day use.
22 March 2018
Update the vendor open trans to mark and update the amount in ax 2012 or AX 7 and D365
VendTransOpen vendTransOpenLoc;
VendTrans vendTransLoc;
SpecTransManager specTransManager;
boolean found;
SpecTrans specTransLoc;
CustVendOpenTransManager managerLoc = CustVendOpenTransManager::construct(ledgerJournalTrans);
select firstonly vendTransLoc
where vendTransLoc.Invoice == ledgerJournalTrans.Invoice
join firstonly vendTransOpenLoc
where vendTransOpenLoc.RefRecId == vendTransLoc.RecId;
specTransManager = SpecTransManager::construct(ledgerJournalTrans);
found = SpecTrans::existByRef(vendTransOpenLoc.DataAreaID,tableNum(VendTransOpen),vendTransOpenLoc.RecId);
if(found == false)
{
managerLoc.updateTransMarked(vendTransOpenLoc,NoYes::Yes);
ttsbegin;
specTransLoc = SpecTrans::findByRef(vendTransOpenLoc.DataAreaID,tableNum(VendTransOpen),vendTransOpenLoc.RecId,true);
specTransLoc.Balance01 = -ledgerJournalTrans.AmountCurDebit;
specTransLoc.update();
ttscommit;
}
else
{
warning(strFmt("%1 Record already marked.",ledgerJournalTrans.Invoice));
}
Subscribe to:
Post Comments (Atom)
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->...
-
{ "Message" : "Please verify that the user is valid and set up correctly." } Sol: System Administration > Se...
-
Please click here to access Custom Workflow step by step process:
-
FormRun formRun = sender.formRun(); Object inventTrans_ds = formRun.dataSource(formDataSourceStr(InventMarking,InventTransO...
Inspiring writings and I greatly admired what you have to say , I hope you continue to provide new ideas for us all and greetings success always for you..Keep update more information..
ReplyDeleteSoftware Testing Training in Chennai
SEO Training in Chennai
Informatica Training in Chennai
Digital Marketing Training in Chennai