Venice
CtLnk::SeekByContact
 
Seeks a Contact-firm link card by its contact number.
 
VARIANT_BOOL SeekByContact (
    enum eSeekMode eSeekMode,
    LONG lCtcNum,
    enum eFirmType eFirmType,
    LONG lFrmNum,
    LONG lFrmSubNum
)
 
Key information
This method uses key number 1 (See SwapKey).
This is a unique key.
 
Key segment information
Segment NameTypeOrderCollation
pCtcNumberLONG (unsigned)Ascending-
pFrmTypeBYTEAscending-
pFrmNumberLONG (unsigned)Ascending-
pFrmSubNumberLONG (unsigned)Ascending-
 
Parameters
eSeekMode
[in] A value of the 'eSeekMode' enumeration.
lCtcNum
[in] The contact number of the contact-firm link you want to seek.
eFirmType
[in] A value of the 'eFirmType' enumeration.
lFrmNum
[in] The firm number of the contact-firm link you want to seek.
lFrmSubNum
[in] The firm subnumber of the contact-firm link you want to seek.
 
Return value
True if the record with the given properties was found, otherwise false.
 
See Also
CreateCtLnk
GetDBStatus
GetNext
 
Samples
 
C++
 
// Seek all contact-firm links for the contact with number 123
DWORD dwCtcNumber = 123;
pCtLnk->SeekByContact (smGreaterOrEqual, dwCtcNumber, ftNone, 0, 0);
while (pCtLnk->GetDBStatus () == 0 && (DWORD)pCtLnk->pCtcNumber.ulVal == dwCtcNumber)
{
    // Process record data

    pCtLnk->GetNext ();
}

C#
 
// Seek all contact-firm links for the contact with number 123
int iCtcNumber = 123;
oCtLnk.SeekByContact (eSeekMode.smGreaterOrEqual, iCtcNumber, eFirmType.ftNone, 0, 0);
while (oCtLnk.GetDBStatus () == 0 && (int)oCtLnk.pCtcNumber == iCtcNumber)
{
    // Process record data

    oCtLnk.GetNext ();
}

VBS
 
' Seek all contact-firm links for the contact with number 123
Dim lCtcNumber
lCtcNumber = 123
Call oCtLnk.SeekByContact(smGreaterOrEqual, lCtcNumber, ftNone, 0, 0)
While oCtLnk.GetDBStatus() = 0 And oCtLnk.pCtcNumber = lCtcNumber
    ' Process record data

    Call oCtLnk.GetNext()
Wend

VB.NET
 
' Seek all contact-firm links for the contact with number 123
Dim lCtcNumber As Long
lCtcNumber = 123
oCtLnk.SeekByContact(eSeekMode.smGreaterOrEqual, lCtcNumber, eFirmType.ftNone, 0, 0)
While oCtLnk.GetDBStatus() = 0 And oCtLnk.pCtcNumber = lCtcNumber
    ' Process record data

    oCtLnk.GetNext()
End While