
I have a very simple trigger to update a few fields based on a formula field but its not updating. The trigger assist in showing the values of the formula field on the edit screen of my quote line items. Can someone please help.
trigger UpdateFieldsFormula on QuoteLineItem (before insert, before update) {
for(QuoteLineItem q:trigger.new)
{
q.Quantity_on_hand__c = q.Product_Quantity_On_Hand__c;
q.Cost_Price__c = q.Product_Cost_Price__c;
q.In_Stock_Price2__c = q.In_Stock_Pricing__c;
}
}
답변 5개