[DllImport("Advapi32.dll", SetLastError = true)][return: MarshalAs(UnmanagedType.SysUInt)] public static extern IntPtr OpenEventLog( string lpUNCServerName, string lpSourceName );
Microsoft documentation: Link
Last updated 1 year ago