GetCaptureCommentFromFilename
The GetCaptureCommentFromFilename function extracts the capture comment from a capture file.
DWORD WINAPIGetCaptureCommentFromFilename(LPSTRlpFilename,
LPSTRlpComment,
DWORDBufferSize);
Parameters
- lpFilename
[in] Pointer to the name of the capture file. - lpComment
[in] Pointer to a pre-allocated string for the comment. - BufferSize
[in] Size of the string.
Return Values
If the function is successful (that is, if the comment is found and copied, or there is no comment in the capture file), the return value is NMERR_SUCCESS.
If the function is unsuccessful, the return value is an error code.
Return code | Description |
---|---|
NMERR_FILE_READ_ERROR | The capture comment cannot be read. |
NMERR_INVALID_FILE_FORMAT | The Comment frame is not a valid file format. |
NMERR_FILE_NOT_FOUND | The file specified by the lpFilename parameter cannot be found. |
NMERR_INVALID_PARAMETER | One of the parameters is specified incorrectly. |
Remarks
Experts and parsers can call the GetCaptureCommentFromFilename function.
To retrieve the comment of a real-time capture, call the GetCaptureComment function.
Requirements
Client | Requires Windows XP, Windows 2000 Professional, or Windows NT Workstation 4.0. |
Server | Requires Windows Server 2003, Windows 2000 Server, or Windows NT Server 4.0. |
Header | Declared in Netmon.h. |
Library | Link to Nmapi.lib. |
DLL | Requires Nmapi.dll. |