Pages

Wednesday, 16 March 2022

Powershell script to to check te application version through app name

$driverversion = "7.5.7"

$version = (Get-WmiObject -Class Win32_Product | where Name -like "Sentinel System Driver Installer*" | select Version).version

If ($version -ge $driverversion){
Write-host "Already same or higher version of driver already installed in the machine"
}

Else {
Write-host "Application not found"
}

No comments:

Post a Comment

test

 # Set the file path you want to check $filePath = "C:\Path\To\Your\File.exe" # Check if file exists if (Test-Path $filePath) {   ...

Search This Blog