C# get serialnr of physical harddisk

Job ID: 33016790

Budget: $10 – $30 USD

Hello,

I need C# code for Windows10 that does the followimg:

Give me the serialnr of the Physical Harddisk (and not of connected removable media like USB drives etc)

So I need a method that I can call like so:

//The serialnr of physical harddisk
s = GetPhysicalHHD_Serialnr()

or

//The serialnr of Windows Systemdrive "c:"
s = GetPhysicalHHD_Serialnr("c:")
Related categories: .NET C# Programming