INtime SDK Help
ReportEvent (iwin32)
INtime SDK v7.1 > About INtime > Alternate APIs > iwin32 API > iwin32 API > ReportEvent (iwin32)

Collects log data in the same format as the Windows ReportEvent function, and passes it to the Windows machine for logging. A null UserID security ID is given.

BOOLEAN ReportEvent(
    HANDLE hEventLog,
    WORD wType,
    Word wCategory,
    DWORD dwEventID,
    PSID lpUserSid,
    WORD wNumStrings,
    DWORD dwDataSize,
    LPCTSTR* lpStrings,
    LPVOID lpRawData);
);

Parameters

hEventLog
Identifies the event log. This parameter should be set to NULL.
wType
Type of event to log. Valid values include:
Value Code Meaning
EVENTLOG_ERROR_TYPE 0x0001 Error event.
EVENTLOG_INFORMATION_TYPE 0x0004 Information event.
EVENTLOG_WARNING_TYPE 0x0002 Warning event.
For more information about event types, see Event Logging in the Win32 SDK.
wCategory
(Event category) This is source-specific information; the category can have any value.
dwEventID
(Event identifier) Specifies the entry in the EventMsg.dll message file. For valid event IDs, see the EventMsg file.
lpUserSid
Ignored; set to NULL.
wNumStrings
Number of insert strings in the array pointed to by the lpStrings parameter. A value of 0 (zero) indicates that no strings exist.
dwDataSize
Number of bytes of event-specific raw (binary) data to write to the log. If this parameter is 0 (zero), no event-specific data exists.
lpStrings
Pointer to a buffer that contains an array of null-terminated strings merged into the message before Event Viewer displays the string. This parameter must be a valid pointer (or NULL), even if wNumStrings is 0 (zero).
lpRawData
Pointer to the buffer that contains the binary data. This parameter must be a valid pointer (or NULL), even if the dwDataSize parameter is 0 (zero).

Return Values

TRUE
Success; the entry was written to the log.
FALSE
Failure. For extended error information, see GetLastError.

Requirements

Versions Defined in Include Link to
INtime 3.0 intime/rt/include/winbase.h windows.h iwin32.lib

Note

This function operates in the real-time portion of your application.

See Also

iwin32 API, iwin32 Overview