StockDocDet::SeekByArtNum (Interface: StockDocDet)
 
Seeks a Stock Document Detail line by its article number.
 
VARIANT_BOOL SeekByArtNum (
    enum eSeekMode eSeekMode,
    BSTR bsArtNum,
    DATE dDocDate
)
 
Key information
This method uses key number 2 (See SwapKey).
This key allows duplicates.
 
Key segment information
Segment NameTypeOrderCollation
pArtNumBSTRAscendingHierarchy
pDocDateDATE (date)Ascending-
 
Parameters
eSeekMode
[in] A value of the 'eSeekMode' enumeration.
bsArtNum
[in] The number of the article of the stock document detail line you want to seek.
dDocDate
[in] The document date of the stock document of which you want to seek a detail line.
 
Return value
True if the record with the given properties was found, otherwise false.
 
See Also
CreateStockDocDet
GetDBStatus
GetNext
 
Samples
 
C++
 
// Seek the data of all detail lines for the article with number = 'Article' of all stock documents
CString strArtNum = "Article";
pStockDocDet->SeekByArtNum (smGreaterOrEqual, (LPCSTR)strArtNum, COleDateTime (0, 0, 0, 0, 0, 0).m_dt);
while (pStockDocDet->GetDBStatus () == 0 && (CString)pStockDocDet->pArtNum == strArtNum)
{
    // Process record data
    
    pStockDocDet->GetNext ();
}

C#
 
// Seek the data of all detail lines for the article with number = 'Article' of all stock documents
string strArtNum = "Article";
oStockDocDet.SeekByArtNum (eSeekMode.smGreaterOrEqual, strArtNum, new DateTime ());
while (oStockDocDet.GetDBStatus () == 0 && oStockDocDet.pArtNum.ToString () == strArtNum)
{
    // Process record data
    
    oStockDocDet.GetNext ();
}

VBS
 
' Seek the data of all detail lines for the article with number = 'Article' of all stock documents
Dim strArtNum
Dim dtDocDate
strArtNum = "Article"
Call oStockDocDet.SeekByArtNum(smGreaterOrEqual, strArtNum, dtDocDate)
While oStockDocDet.GetDBStatus() = 0 And oStockDocDet.pArtNum = strArtNum
    ' Process record data

    Call oStockDocDet.GetNext()
Wend

VB.NET
 
' Seek the data of all detail lines for the article with number = 'Article' of all stock documents
Dim strArtNum As String
Dim dtDocDate As Date
strArtNum = "Article"
oStockDocDet.SeekByArtNum(eSeekMode.smGreaterOrEqual, strArtNum, dtDocDate)
While oStockDocDet.GetDBStatus() = 0 And oStockDocDet.pArtNum = strArtNum
    ' Process record data

    oStockDocDet.GetNext()
End While