diff --git a/win32/installer/zoitechat.iss.tt b/win32/installer/zoitechat.iss.tt index 871f95d4..a07e4aec 100644 --- a/win32/installer/zoitechat.iss.tt +++ b/win32/installer/zoitechat.iss.tt @@ -241,8 +241,14 @@ end; ///////////////////////////////////////////////////////////////////// function CheckVCInstall(): Boolean; +var + Installed: Cardinal; begin - Result := FileExists(GetSysDir() + 'vcruntime140.dll');; + Result := False; + if RegQueryDWordValue(HKLM64, 'SOFTWARE\Microsoft\VisualStudio\14.0\VC\Runtimes\x64', 'Installed', Installed) then + Result := Installed = 1 + else if RegQueryDWordValue(HKLM, 'SOFTWARE\Microsoft\VisualStudio\14.0\VC\Runtimes\x64', 'Installed', Installed) then + Result := Installed = 1; end; procedure UpdateVCRedistComponentState;