Merge pull request #5 from Romanitho/dev

Change MS Visual C++ detection
pull/8/head v1.4.1
Romain 2022-02-20 22:54:30 +01:00 committed by GitHub
commit ba83f2b531
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -33,7 +33,7 @@ param(
function Check-Prerequisites{
#Check if Visual C++ 2019 installed
$app = "Microsoft Visual C++*2019*"
$path = Get-ChildItem -Path HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall, HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall | Get-ItemProperty | Where-Object {$_.DisplayName -like $app } | Select-Object -Property Displayname, DisplayVersion
$path = Get-Item HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\*, HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\* | Where-Object { $_.GetValue("DisplayName") -like $app}
#If not installed, ask for installation
if (!($path)){