Skip to content

Instantly share code, notes, and snippets.

@manilz
Forked from brad-anton/Lookup CLSID in PowerShell
Created February 24, 2023 01:59
Show Gist options
  • Save manilz/4e78d861aa2f05ff4b1fc42f3fc9d8b0 to your computer and use it in GitHub Desktop.
Save manilz/4e78d861aa2f05ff4b1fc42f3fc9d8b0 to your computer and use it in GitHub Desktop.
function Lookup-Clsid
{
Param([string]$clsid)
$CLSID_KEY = 'HKLM:\SOFTWARE\Classes\CLSID'
If ( Test-Path $CLSID_KEY\$clsid) {
$name = (Get-ItemProperty -Path $CLSID_KEY\$clsid).'(default)'
$dll = (Get-ItemProperty -Path $CLSID_KEY\$clsid\InProcServer32).'(default)'
}
$name, $dll
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment