Property lastError.code Overload Gets (System.Runtime.InteropServices.Marshal.GetLastWin32Error) or sets (API SetLastError) the Windows API last error code of this thread. public static int code { get; set; } Property Value int