List All Files Associated With The Driver

Is there a way to list all of the files with their path associated with the driver.

For instance, Intel Graphics driver has many files associate with it. (Screen Shot of Device Manager listing all of the files of Intel Graphics driver.)

The code I am using is:

# Export all driver names to a text file
Get-WmiObject win32_SystemDriver | select name | foreach {$_.name} | Out-File C:\driverName.csv

# Read driver name from file.
$driver =  Get-Content "C:\driverName.csv"

# Get the file path of the driver
$path = (Get-WmiObject win32_SystemDriver | Where-Object name -match $driverName).PathName

# Extract information from the file path and export it to CSV
(Get-Item $path).VersionInfo  | Select FileDescription, ProductVersion, FileVersion, FileName | Export-Csv -Path C:\FileVersion.csv

But the above code only lists one main .sys file.

While researching, I found out that...

get-wmiobject -class "Win32_PrinterDriver" -namespace "root\CIMV2" -computername $Server

Win32_PrinterDriver class has extra set of properties like DataFile, ConfigFile, DependentFile and etc.

However, it only lists printer drivers.
Is there a way to list all of the driver or possibly a different class that would list other files as well?



June 25th, 2015 7:58pm

You should find what you need in the Win32_PnPSignedDriverCIMDataFile class.
Free Windows Admin Tool Kit Click here and download it now
June 26th, 2015 5:27pm

Hi Sayyam197,

Based on my research, I haven't found a good method to list all the files under driver file details, this article is for your reference:

http://blogs.technet.com/b/ben_parker/archive/2009/11/13/how-can-i-get-network-adapter-driver-filename-and-version-using-powershell.aspx

I also tried "driverquery /si /FO CSV".

Best Regards,

Anna Wang

June 30th, 2015 6:09am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics