POrder::SeekByDocDate (Interface: POrder)
 
Seeks a Purchase Order by its document date.
 
VARIANT_BOOL SeekByDocDate (
    enum eSeekMode eSeekMode,
    DATE dDocDate,
    BSTR bsBook,
    LONG lDocNum
)
 
Key information
This method uses key number 3 (See SwapKey).
This is a unique key.
 
Key segment information
Segment NameTypeOrderCollation
pDocDateDATE (date)Ascending-
pBookBSTRAscendingCase insensitive
pDocNumLONG (unsigned)Ascending-
 
Parameters
eSeekMode
[in] A value of the 'eSeekMode' enumeration.
dDocDate
[in] The document date of the Purchase Order you want to seek.
bsBook
[in] The book code of the Purchase Order you want to seek.
lDocNum
[in] The document number of the Purchase Order you want to seek.
 
Return value
True if the record with the given properties was found, otherwise false.
 
See Also
CreatePOrder
 
Samples
 
C++
 
// Seek the document with document date = 28/06/2022 and book code = 'Book' and document number = 12
if (pPOrder->SeekByDocDate (smEqual, COleDateTime (2022, 6, 28, 0, 0, 0).m_dt, "Book", 12))
    // Process record data

C#
 
// Seek the document with document date = 28/06/2022 and book code = 'Book' and document number = 12
if (oPOrder.SeekByDocDate (eSeekMode.smEqual, new DateTime (2022, 6, 28), "Book", 12))
    // Process record data

VBS
 
' Seek the document with document date = 28/06/2022 and book code = 'Book' and document number = 12
If oPOrder.SeekByDocDate(smEqual, #6/28/2022#, "Book", 12) Then
    ' Process record data
End If

VB.NET
 
' Seek the document with document date = 28/06/2022 and book code = 'Book' and document number = 12
If oPOrder.SeekByDocDate(eSeekMode.smEqual, #6/28/2022#, "Book", 12) Then
    ' Process record data
End If