IDebugControl3::SetNextEventIndex method (dbgeng.h)

The SetNextEventIndex method sets the next event for the current target by selecting the event from the static list of events for the target, if such a list exists.

Syntax

HRESULT SetNextEventIndex(
  [in]  ULONG  Relation,
  [in]  ULONG  Value,
  [out] PULONG NextIndex
);

Parameters

[in] Relation

Specifies how to interpret Value when setting the index of the next event. Possible values are: DEBUG_EINDEX_FROM_START, DEBUG_EINDEX_FROM_END, and DEBUG_EINDEX_FROM_CURRENT.

[in] Value

Specifies the index of the next event relative to the first, last, or current event. The interpretation of Value depends on the value of Relation, as follows.

Value of Relation Next Event Index
DEBUG_EINDEX_FROM_START Value.
DEBUG_EINDEX_FROM_END Number of events minus Value.
DEBUG_EINDEX_FROM_CURRENT The current event index plus Value.
 

The resulting index must be greater than zero and one less than the number of events returned by GetNumberEvents.

[out] NextIndex

Receives the index of the next event. If NextIndex is NULL, this information is not returned.

Return value

This method may also return error values. See Return Values for more details.

Return code Description
S_OK
The method was successful.

Remarks

If the specified event is the same as the current event, this method does nothing. Otherwise, this method sets the execution status of the target to DEBUG_STATUS_GO (and notifies the event callbacks). When WaitForEvent is called, the engine will generate the specified event for the event callbacks and set it as the current event.

This method is only useful if the target offers a list of events.

Requirements

Requirement Value
Target Platform Desktop
Header dbgeng.h (include Dbgeng.h)

See also

GetCurrentEventIndex

GetNumberEvents

IDebugControl3