Search
Module:
Directory

   Desktop Functions:

   Smart Device Functions:


Show Recent Changes
Subscribe (RSS)
Misc. Pages
Comments
FAQ
Helpful Tools
Playground
Suggested Reading
Website TODO List
Download Visual Studio Add-In

RegisterTraceGuids (advapi32)
 
.
Summary
The RegisterTraceGuids function registers an event trace provider and the event trace classes that it uses to generate events. This function also specifies the function the provider uses to enable and disable tracing.

C# Signature:

[DllImport("advapi32", EntryPoint = "RegisterTraceGuidsW", CharSet = CharSet.Unicode, ExactSpelling = true)]
static extern unsafe uint RegisterTraceGuids([In] EtwProc cbFunc, [In] void* context, [In] ref Guid controlGuid, [In] uint guidCount, ref TraceGuidRegistration guidReg, [In] string mofImagePath, [In] string mofResourceName, out ulong regHandle);

User-Defined Types:

EtwProc (http://windowssdk.msdn.microsoft.com/library/default.asp?url=/library/en-us/etw/etw/controlcallback.asp)

    delegate uint EtwProc(uint requestCode, IntPtr requestContext, IntPtr bufferSize, byte* buffer);

TraceGuidRegistration (http://windowssdk.msdn.microsoft.com/library/default.asp?url=/library/en-us/etw/etw/trace_guid_registration.asp)

    [StructLayout(LayoutKind.Sequential)]
    internal struct TraceGuidRegistration
    {
        internal unsafe System.Guid* Guid;
        internal unsafe void* RegHandle;
    }

Notes:

None.

Tips & Tricks:

Please add some!

Sample Code:

http://windowssdk.msdn.microsoft.com/library/en-us/etw/etw/registering_an_event_trace_provider.asp

Documentation
RegisterTraceGuids @msdn on MSDN

Please edit this page!

Do you have...

  • helpful tips or sample code to share for using this API in managed code?
  • corrections to the existing content?
  • variations of the signature you want to share?
  • additional languages you want to include?

Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).

 
Access PInvoke.net directly from VS:
Terms of Use
Edit This Page
Find References
Show Printable Version
Revisions