// GetQuickFixEngineeringReport.cs // // Reports Installed Hotfixes via WMI (Win32_QuickFixEngineering). // // Requires the System.Management package: // dotnet new console -o QuickFixEngineeringReport // dotnet add package System.Management // (replace the generated Program.cs with this file, then dotnet run) // On .NET Framework, System.Management is already available — just // add a reference to it in your project. using System; using System.Management; var searcher = new ManagementObjectSearcher("SELECT HotFixID, Description, InstalledOn, InstalledBy FROM Win32_QuickFixEngineering"); int count = 0; foreach (ManagementObject item in searcher.Get()) { Console.WriteLine($"HotFixID: {item["HotFixID"]}"); Console.WriteLine($"Description: {item["Description"]}"); Console.WriteLine($"InstalledOn: {item["InstalledOn"]}"); Console.WriteLine($"InstalledBy: {item["InstalledBy"]}"); Console.WriteLine(new string('-', 40)); count++; } if (count == 0) { Console.WriteLine("No Installed Hotfixes found."); } else { Console.WriteLine($"\n{count} Installed Hotfixes found."); }