PLP-SystemInfo is compatible with the following frameworks:
- .NET 5 or higher
- .Net Core 2 - 3.1
- .Net Standard 2.0 & 2.1
- .Net Framework 4.6.1 or higher
Dependencies:
- System.Management
- System.Win32
PLP-SystemInfo is available as a NuGet Package
The package contains in the namespace PLP_SystemInfo one class for reading system information, SystemInfo.cs and 3 more namespaces: Collections, ComponentInfo and Models,
The namespaces Collections and Models are largely ignored for use. They only provide the corresponding classes for the outputs.
The class SystemInfo contains mainly methods to read general system values.
Each method has a return value which simplifies the usage.
usingPLP_SystemInfo;stringuserName=SystemInfo.UserName;//Retruns the username of the current userstringmachineName=SystemInfo.MachineName;//Retruns the name of the machine.boolb=SystemInfo.IsDarkModeEnabled;// Returns a bool value that reflects whether the Windows darkmode is enabledstrings=SystemInfo.GetWindowsAccentColor();// Returns the Windows accent color as HEX value.Colorc=SystemInfo.GetAccentColor();// Returns the Windows accent color as a Color value.The namespace PLP_SystemInfo.ComponentInfo contains different classes to read out the most important PC components.
usingPLP_SystemInfo.ComponentInfo;usingPLP_SystemInfo.Models;Boardb=BoardInfo.GetMotherboard();// Returns an object of type **Board** with manufacturer and model.BIOSbios=BoardInfo.GetBIOSInfo();// Returns an object of type **BIOS** with manufacturer and version.usingPLP_SystemInfo.ComponentInfo;stringos=OSInfo.GetOperatingSystemInfo();// Returns a string with OS name and architecture.usingPLP_SystemInfo.ComponentInfo;usingPLP_SystemInfo.Collections;ProcessorCollectionprocessors=ProcessorInfo.GetProcessors();// Returns a collection of type **Processor** containing information such as name, architecture, cores, threads, cache and clock speed.usingPLP_SystemInfo.ComponentInfo;usingPLP_SystemInfo.Collections;RamCollectionram=RamInfo.GetRamInfo();// Returns a collection of type **RAM** containing information for each installed ram module such as manufacturer, frequency, voltage and capacity.longtotalRam=RamInfo.GetInstalledRAMSize();// Returns a long value of the installed GB of RAM.doubled1=RamInfo.GetTotalUsableRam();// Returns the total useable ram in GB.doubled2=RamInfo.GetHardwareReservedRam();// Returns the harware reserved ram in MB.doubled3=RamInfo.GetRamInUse();// Returns the used ram in GB.doubled4=RamInfo.GetAvailableRam();// Returns the available ram.usingPLP_SystemInfo.ComponentInfo;usingPLP_SystemInfo.Collections;GraphicsCollectiongraphics=GraphicsInfo.GetGraphicscardInfo();// Returns a collection of type **GraphicsCard** containing information such as name and driver version.To get the information from the collections, simply use a foreach loop, e.g:
foreach(varitemin<yourCollection>){Console.WriteLine(item.<Property>);}This software is released under the Apache 2.0 license