Venice
Sales::SeekByRepresent
 
Seeks a Sales Document by its representative.
 
VARIANT_BOOL SeekByRepresent (
    enum eSeekMode eSeekMode,
    BSTR bsRepresent
)
 
Key information
This method uses key number 8 (See SwapKey).
This key allows duplicates.
 
Key segment information
Segment NameTypeOrderCollation
pRepresentativeBSTRAscendingCase insensitive
 
Parameters
eSeekMode
[in] A value of the 'eSeekMode' enumeration.
bsRepresent
[in] The representative of the Sales Document you want to seek.
 
Return value
True if the record with the given properties was found, otherwise false.
 
See Also
CreateSales
GetDBStatus
GetNext
 
Samples
 
C++
 
// Seek all Sales Documents with representative = 'Repr_001'
pSales->SeekByRepresent (smEqual, "Repr_001");
while (pSales->GetDBStatus () == 0 && (CString)pSales->pRepresentative == "Repr_001")
{
    // Process record data
    
    pSales->GetNext ();    
}

C#
 
// Seek all Sales Documents with representative = 'Repr_001'
oSales.SeekByRepresent (eSeekMode.smEqual, "Repr_001");
while (oSales.GetDBStatus () == 0 && oSales.pRepresentative.ToString () == "Repr_001")
{
    // Process record data
    
    oSales.GetNext ();
}

VBS
 
' Seek all Sales Documents with representative = 'Repr_001'
Call oSales.SeekByRepresent(smEqual, "Repr_001")
While oSales.GetDBStatus() = 0 And oSales.pRepresentative = "Repr_001"
    ' Process record data

    Call oSales.GetNext()
Wend

VB.NET
 
' Seek all Sales Documents with representative = 'Repr_001'
oSales.SeekByRepresent(eSeekMode.smEqual, "Repr_001")
While oSales.GetDBStatus() = 0 And oSales.pRepresentative = "Repr_001"
    ' Process record data

    oSales.GetNext()
End While