📚 SAP Business One SDK Help

Invoice Document Lines - SetCurrentLine Method Sample
See Also

Description

The following sample shows how to set the line number to the third line of the rows section of an invioce document (only if the third line exists).
Dim vInvoice As SAPbobsCOM.Documents
Set vInvoice = vCmp.GetBusinessObject(oInvoices)
    vInvoice.GetByKey ("63")
    ' The count starts from 0, therefore the line number parameter is 2.
    vInvoice.Lines.SetCurrentLine (2)