Whenever a debugging session is accessible, there is a last event. This is the event that caused the session to become accessible. The event target is the target which generated the last event. When the session becomes accessible, the current target is set to the event target. The details of the last event are returned by GetLastEventInformation. The instruction pointer for the last event and the memory at the instruction pointer when the event occurred are returned by the Request operations DEBUG_REQUEST_GET_CAPTURED_EVENT_CODE_OFFSET and DEBUG_REQUEST_READ_CAPTURED_EVENT_CODE_STREAM.
If the target is a crash dump file, the last event is the last event that occurred before the dump file was created. This event is stored in the dump file and the engine generates it for the event callbacks when the dump file is acquired as a debugging target.
If the target is a user-mode Minidump, the dump file generator may store an additional event. Typically, this is the event that provoked the generator to save the dump file. Details of this event are returned by GetStoredEventInformation and the Request operations DEBUG_REQUEST_TARGET_EXCEPTION_CONTEXT, DEBUG_REQUEST_TARGET_EXCEPTION_THREAD, and DEBUG_REQUEST_TARGET_EXCEPTION_RECORD.
Dump files may contain a static list of events. Each event represents a snapshot of the target at a particular point in time. The number of events in this list is returned by GetNumberEvents. For a description of each event in the list, use GetEventIndexDescription. To set an event from this list as the current event, use the method SetNextEventIndex; after calling WaitForEvent, the event becomes the current event. To determine which event in the list is the current event, use GetCurrentEventIndex.