DSGetLogEventIds

Use the DSGetLogEventIds function to return a list of log event IDs for a run of a job invocation.

Syntax


IdList = DSGetLogEventIds (JobHandle, RunNumber, EventTypeFilter)

JobHandle is the handle for the job as derived from DSAttachJob.

RunNumber identifies the job invocation run for which event IDs are returned. Usually a zero value requests IDs for the most recent run of the job invocation. To retrieve details for earlier runs, supply negative values, such as -1 for details about the run before the most recent, -2 for details about the run before that, and so forth. Where explicit run numbers are known, you can retrieve details by supplying the run number as a positive value.

EventTypeFilter restricts the types of event log entry for which IDs are returned. By default, IDs for all log entries are returned. Include characters in the filter string to restrict entries as follows:
I
Informational
W
Warning
F
Fatal
S
Start or End events
B
Batch or Control events
R
Purge or reset events
J
Reject events
IdList is returned as a list of positive integers that identify the required log events. In the case of an error, IdList can also be returned as a negative integer, in which case it contains one of these error codes:
DSJE.BADHANDLE
Invalid JobHandle.
DSJE.BADTYPE
Invalid EventTypeFilter.
DSJE.BADVALUE
Invalid RunNumber.

Remarks

To use this method, the program needs to have previously acquired a job handle by calling DSAttachJob.

The run number for a job invocation is reset when the job is compiled, thus it is not possible to use this method to retrieve job event IDs for runs that occurred prior to the most recent job compilation.