PdcPurchaseInvoiceHeader.SetTermsOfPayment

From External Bemet Wiki
Jump to navigation Jump to search

Declaration

SetTermsOfPaymentId(TermsOfPaymentId as Integer) as Boolean

Description

Sets the terms of payment ID of the purchase invoice.

Notes

Automatically after setting the terms of payment id, the expirationdate is calculated with the number of days.

Code example

The following code example changes the terms of payment ID and saves the invoice.

dim objPI

  set objPI = Pdc.logistics.PurchaseInvoices.Open("157625")
  if objPI.SetTermsOfPaymentID("02") then
    if not objPI.Save then
      msgbox pdc.LastError
    end if
  else
    msgbox pdc.LastError
  end if

Availability

Available since April 2014 (Version 4.3 onwards)