TraceDumpEx

[This Tracing API is available for use in the operating systems listed in the Requirements section. It may be altered or unavailable in subsequent versions. Instead use the Event Tracing API.]

The TraceDumpEx function outputs a hexadecimal dump of size dwByteCount. TraceDumpEx differentiates itself from TraceDump in its extended (Ex) output options, implemented through the use of non-zero dwFlags values. Output from TraceDumpEx can include information with a prefix of the name associated with the calling service or application's dwTraceID, the associated thread identifier used with the RRAS tracing functionality, the current system time, and a brief description of the dump.

DWORD TraceDumpEx(
  DWORD dwTraceID,
  DWORD dwFlags,
  LPBYTE lpbBytes,
  DWORD dwByteCount,
  DWORD dwGroupSize,
  BOOL bAddressPrefix,
  LPCTSTR lpszPrefix
);

Parameters

  • dwTraceID
    [in] Handle returned by the calling service or application's initial TraceRegister call.

  • dwFlags
    [in] Specifies the flags that control appearance of TraceDumpEx output. Ensure dwFlags is one or more of the following:

    • TRACE_NO_STDINFO
      Suppresses output of the standard information associated with dwTraceID
    • TRACE_USE_MASK
      Determines whether file and/or console output is generated by comparing the high-order word of dwFlags against registry values FileTracingMask and ConsoleTracingMask.
  • lpbBytes
    [in] Pointer to the buffer from which the hex dump is to be generated.

  • dwByteCount
    [in] Specifies the number of bytes to dump from the buffer.

  • dwGroupSize
    [in] Specifies the byte grouping size of the output. Valid values are 1, 2, or 4.

  • bAddressPrefix
    [in] Specifies the Boolean value that determines whether each line of the hex dump is prefixed with its memory address. A value of TRUE includes the memory address.

  • lpszPrefix
    [in] Pointer to the prefix.

Return Value

Successful execution of TraceDump returns the number of characters output.

Otherwise, TraceDump returns zero. Call GetLastError to get the error code.

Remarks

TraceDumpEx generates debug-style dumps. The byte ordering of the dump is dependent on the processor. Also note that the last line of the dump is padded with zeroes.

Requirements

Server Requires Windows Server 2003 or Windows 2000 Server.
Redistributable Requires RRAS download on Windows NT Server 4.0 SP3 and later.
Header

Declared in Rtutils.h.

Library

Use Rtutils.lib.

DLL Requires Rtutils.dll.
Unicode

Implemented as TraceDumpExW (Unicode) and TraceDumpExA (ANSI).

See Also

About Tracing
Tracing Reference
TraceDump
TraceRegisterEx
TracePrintfEx
TraceVprintfEx
TracePutsEx