@msdn=http://msdn2.microsoft.com/en-us/library/ms793467.aspx @pinvoke=http://pinvoke.net/$$$.htm Summary: A DIFXAPILOGCALLBACK-typed function is an application-supplied callback function that an application registers with DIFxAPI by calling DIFXAPISetLogCallback. DIFxAPI calls the callback function to log events that occur during DIFxAPI operation. !!!!C# Signature: public delegate void DIFXAPILOGCALLBACK(DIFXAPI_LOG EventType, Int32 ErrorCode, [MarshalAs(UnmanagedType.LPTStr)] string EventDescription, IntPtr CallbackContext); !!!!VB Signature: Public Delegate Sub DIFXAPILOGCALLBACK(ByVal EventType As DIFXAPI_LOG, ByVal ErrorCode As Int32, <MarshalAs(UnmanagedType.LPTStr)> ByVal EventDescription As String, ByVal CallbackContext As IntPtr) !!!!User-Defined Types: [DIFXAPI_LOG] !!!!Alternative Managed API: Do you know one? Please contribute it! !!!!Notes: None. !!!!Tips & Tricks: To use this function you just need difxapi.dll of appropriate architecture from Windows Server 2008/Vista WDK. The DriverStore will be created automatically for you. !!!!Sample Code: C#: public static void DIFxAPILogCallbackFunc(DIFXAPI_LOG EventType, Int32 ErrorCode, string EventDescription, IntPtr CallbackContext) { switch (EventType) { case DIFXAPI_LOG.DIFXAPI_SUCCESS: Console.WriteLine("SUCCESS: {0}. Error code: {1}", EventDescription, ErrorCode); break; case DIFXAPI_LOG.DIFXAPI_INFO: Console.WriteLine("INFO: {0}. Error code: {1}", EventDescription, ErrorCode); break; case DIFXAPI_LOG.DIFXAPI_WARNING: Console.WriteLine("WARNING: {0}. Error code: {1}", EventDescription, ErrorCode); break; case DIFXAPI_LOG.DIFXAPI_ERROR: Console.WriteLine("ERROR: {0}. Error code: {1}", EventDescription, ErrorCode); break; } } VB: Public Sub DIFxAPILogCallbackFunc(ByVal EventType As DIFXAPI_LOG, ByVal ErrorCode As Int32, ByVal EventDescription As String, ByVal CallbackContext As IntPtr) Select Case EventType Case DIFXAPI_LOG.DIFXAPI_SUCCESS Console.WriteLine("SUCCESS: {0}. Error code: {1}", EventDescription, ErrorCode) Exit Sub Case DIFXAPI_LOG.DIFXAPI_INFO Console.WriteLine("INFO: {0}. Error code: {1}", EventDescription, ErrorCode) Exit Sub Case DIFXAPI_LOG.DIFXAPI_WARNING Console.WriteLine("WARNING: {0}. Error code: {1}", EventDescription, ErrorCode) Exit Sub Case DIFXAPI_LOG.DIFXAPI_ERROR Console.WriteLine("ERROR: {0}. Error code: {1}", EventDescription, ErrorCode) Exit Sub End Select End Sub Documentation: DIFXAPILOGCALLBACK@msdn on MSDN
Edit difxapi.DIFXAPILO...
You do not have permission to change this page. If you feel this is in error, please send feedback with the contact link on the main page.