📚 SAP Business One SDK Help

GetNextSerialNumber Method
See Also 
series
The series for which to get the next number
ObjectType
The object type for which to get the serial number

Description

Returns the next number in the series associated with the user-defined object (UDO).

Syntax

Visual Basic
Public Function GetNextSerialNumber( _
   ByVal series As String, _
   Optional ByVal ObjectType As String = "" _
) As Long

Parameters

series
The series for which to get the next number
ObjectType
The object type for which to get the serial number

Remarks

Relevant only for UDOs of type Document initiated with the Manage Series service.

Use this method to automatically set or display the document number on your form when the form is connected to a user-defined object of type Document.

In SAP Business One, document objects -- such as Invoice or Purchase Order -- are typically automatically numbered according to a predefined series associated with the document object.

For more information, see User-Defined Objects in the UI API.

See Also