|
Browses the file for a Material Assets card. |
|
|
LONG Browse ( VARIANT_BOOL bFromCurrPos ) |
|
|
Parameters | bFromCurrPos | [in] When this parameter is set to true the browse will use the current position of the file and the key that was set by the previous SeekBy-method. If the parameter is false the browse will be positioned at the beginning of the file and the key will be the last one that was manually selected in the browse. | | Return value |
A LONG containing the system number of the selected record, 0 if no record was selected. | | Remarks |
| This method can only be used if user interface is allowed (parameter bWithUserInterface is set to true in the Logon method), because a record can only be selected using the browse dialog. |
|
|
See Also |
|
|
|
Samples |
|
|
C++ |
|
CString strCode = "CAR_001";
long lSysNum;
if (pMaCrd->SeekByCode (smEqual, (LPCSTR)strCode))
// Browse using the key 'MCR_COD' (code) and positioned on the record found by SeekByCode
lSysNum = pMaCrd->Browse (VARIANT_TRUE);
else
// Browse using the last key that was manually selected and positioned at the beginning of the file
lSysNum = pMaCrd->Browse (VARIANT_FALSE);
|
|
|
C# |
|
string strCode = "CAR_001";
int iSysNum;
if (oMaCrd.SeekByCode (eSeekMode.smEqual, strCode))
// Browse using the key 'MCR_COD' (code) and positioned on the record found by SeekByCode
iSysNum = oMaCrd.Browse (true);
else
// Browse using the last key that was manually selected and positioned at the beginning of the file
iSysNum = oMaCrd.Browse (false);
|
|
|
VBS |
|
Dim strCode
Dim lSysNum
strCode = "CAR_001"
If oMaCrd.SeekByCode(smEqual, strCode) Then
' Browse using the key 'MCR_COD' (code) and positioned on the record found by SeekByCode
lSysNum = oMaCrd.Browse(True)
Else
' Browse using the last key that was manually selected and positioned at the beginning of the file
lSysNum = oMaCrd.Browse(False)
End If
|
|
|
VB.NET |
|
Dim strCode As String
Dim lSysNum As Long
strCode = "FAC"
If oMaCrd.SeekByCode(eSeekMode.smEqual, strCode) Then
' Browse using the key 'MCR_COD' (code) and positioned on the record found by SeekByCode
lSysNum = oMaCrd.Browse(True)
Else
' Browse using the last key that was manually selected and positioned at the beginning of the file
lSysNum = oMaCrd.Browse(False)
End If
|
|