Skip to Content
Sep 09, 2009 at 08:27 AM

Qty x Price After Discount not Tally with Line Total


Hi All,

This customer wants to be able to enter the Price After Discount in the Marketing Document.

So, I diligently created a UDF (U_PrAftDisc). Then I also created some formatted searches.

Taking Sales Order as example,

Quantity = 6 (no Formatted Search)

Unit Price = SGD 63.68 (system default taking from Price List linked to the Customer)

Discount % = 70.01 (no formatted search, but will change when Line Total changes OR user put in a discount).

Pr Aft Discount (U_PrAftDisc) = SGD 19.10 (has formatted search, trigger when System Price After Discount is changed)

(Formatted Seasrch = defaults to System Price After Discount)

Price After Discount (system) = SGD 19.10 (rounded from to 2 decimal places from 19.097632)

Line Total = SGD 114.60 (has formatted search, trigger when Pr After Discount is changed).

(Formatted Search = Pr After Discount x Quantity)

The Sales Order is Added.

The Sales Order is re-called out.

It is found that the LineTotal is changed to 114.59 and not 114.60. Users always have to re-enter the Pr after Discount to correct the Line total.

The Decimal Settings at the General Settings are 2 for Price, Amount and Percent.

Anyone has similar scenarios. How can I create the Price after Discount for entry?