Muokkaa

Jaa


StartTracingSession

The C++ Build Insights SDK is compatible with Visual Studio 2017 and later. To see the documentation for these versions, set the Visual Studio Version selector control for this article to Visual Studio 2017 or later. It's found at the top of the table of contents on this page.

The StartTracingSession function starts a tracing session. Executables calling this function must have administrator privileges.

Syntax

RESULT_CODE StartTracingSession(
    const char*                    sessionName,
    const TRACING_SESSION_OPTIONS& options);

RESULT_CODE StartTracingSession(
    const wchar_t*                 sessionName,
    const TRACING_SESSION_OPTIONS& options);

Parameters

sessionName
The name of the tracing session to start. Use the same name when calling StopTracingSession or any other stop trace function.

options
Pointer to a TRACING_SESSION_OPTIONS object. Use this object to select which events should be collected by the tracing session.

Return Value

A result code from the RESULT_CODE enum.