i made custom made sales quote but when i click create order everything works but totals are not updating the way they should and they stay 0
any suggestions? it seems that they are calculated fields
i made custom made sales quote but when i click create order everything works but totals are not updating the way they should and they stay 0
any suggestions? it seems that they are calculated fields
i fixed it by using RedistributeTotalsOnAfterValidate() on trigger OnAfterGetCurrRecord() and it works very well
Updating tax amount in the sales order field is not a good idea. CuryTaxTotal field in sales order is calculated field. It is calculated from SOTaxTran lines. So, in order to update tax amount in sales order you actually need to insert SOTaxTran lines into Taxes view of the SOOrderEntry graph.
Something like that:
//indicate that taxes are inserted in manual mode
TaxAttribute.SetTaxCalc<SOLine.taxCategoryID>(graph.Transactions.Cache, null, TaxCalc.ManualCalc);
// insert SOTaxTran
SOTaxTran newTaxTran= new SOTaxTran();
newTaxTran.TaxRate = 0.1; //put your actual values here
newTaxTran.CuryTaxableAmt = 100; //put your actual values here
newTaxTran.CuryTaxAmt = 10; //put your actual values here
var taxTran = graph.Taxes.Insert(newTaxTran);
--
Terrance
CRM Admin | Apps4Rent
i solved this but i had to add a button and call a local procedure called redistribute totals but it doesn't work if you have not open the page already and added the records like when i create a sales order, i'll check what you suggested
You should check the property update propagation and mimic exactly what the other documents (sales quote / order) does in the standard.
Sohail Ahmed
691
YUN ZHU
646
Super User 2025 Season 1
Mansi Soni
495