TracePutsEx

[This is preliminary documentation and subject to change.]

The TracePutsEx function is an efficient way to retrieve information associated with a registered service or application's identifier (dwTraceID). TracePutsEx differs from TracePuts in its extended (Ex) flexibility with regard to output, achieved through the use of non-zero flags implemented with dwFlags. TracePutsEx also outputs the string literal passed as the function's second argument.

DWORD TracePutsEx(
  IN DWORD dwTraceID,
  IN DWORD dwFlags OPTIONAL,
  IN LPCTSTR lpszString
);
 

Parameters

dwTraceID
The handle returned by the calling service or application's initial TraceRegister call.
dwFlags
Flags that control appearance of TracePutsEx 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 will be generated by comparing the high-order word of dwFlags against registry values FileTracingMask and ConsoleTracingMask.
lpszString
The string to be output.

Return Values

Successful execution of TracePuts returns the number of characters output, excluding the terminating null-character.

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

QuickInfo

  Windows NT: Use version 5.0 and later.
  Windows: Unsupported.
  Windows CE: Unsupported.
  Header: Declared in rtutils.h.
  Import Library: Link with rtutils.lib.

See Also

TracePuts, TraceRegisterEx, TraceDeregisterEx, TracePrintfEx, TraceVprintfEx, TraceDumpEx, GetLastError