Hi everyone,
i’m facing a problem when i populate the Sales quotes lines from an imported file, everything is working fine when the lines were populated, but when i choose a customer from the header field, the fields returns zero for all the rows :
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/a3c5bc0f-b8cb-48a3-ad79-eb56f4334c85.png)
and after choosing a customer:
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/e810a77b-3110-438b-b995-3c6b77b6051f.png)
i tried to use RowUpdated to get the old values back if the new value is 0 :
public static bool IsActive() => true;
protected virtual void _(Events.RowUpdated<CROpportunityProducts> e)
{
var nR = e.Row;
var oR = e.OldRow;
var nUnitPrice = nR.CuryUnitPrice;
var oUnitPrice = oR.CuryUnitPrice;
if (nUnitPrice == 0)
{
nR.CuryUnitPrice = oUnitPrice;
}
}
the code works fine, but the Ext Price is still showing 0, and automatically the Amount field also:
![](https://uploads-us-west-2.insided.com/acumatica-en/attachment/716c6de2-84bc-4727-9a63-ed4e7591084a.png)
Any thoughts?
Best answer by aiwan
View original