Forcing Price override for SO_Invoice Line

SOLVED

I'm currently trying to integrate SO_Invoice using BOI and needing to override pricing on the line item,

below is snippet of the code on the line level

 retVal = oSOInvoice.oLines.nAddLine()
 retVal = oSOInvoice.oLines.nSetValue("ItemCode$", "XX")
 retVal = oSOInvoice.oLines.nSetValue("ItemType$", "1")
 retVal = oSOInvoice.oLines.nSetValue("ItemCodeDesc$", "TestItem1")
 retVal = oSOInvoice.oLines.nSetValue("WarehouseCode$", "200")
 retVal = oSOInvoice.oLines.nSetValue("PriceOverridden$", "Y")
 retVal = oSOInvoice.oLines.nSetValue("UnitPrice", 0.00000)
 retVal = oSOInvoice.oLines.nSetValue("TaxClass$", "NT")
 retVal = oSOInvoice.oLines.nSetValue("QuantityOrdered", 1.00000)
 retVal = oSOInvoice.oLines.nSetValue("QuantityShipped", 1.00000)
 retVal = oSOInvoice.oLines.nWrite()

The result in Sage is still showing original price of this item. Is there any other setting that needs to be done or any parameter I need to set via BOI?

Parents Reply
  • 0 in reply to TonyCah

    Header: SalesOrderNo

    Detail: OrderLineKey

    Do not include CustomerNo, ItemCode... or any such fields that should come from the SO data, unless you are adding a new line (or updating something like the line warehouse). 

    Use the minimum number of fields (OrderLineKey, QuantityShipped, UnitPrice...), and it can't mysteriously add a line not found on the SO.

Children