Background: I wrote the application on Qt5.7 MSVC. Collected all dll-s using the utility windeployqt.exe. Made the installer using the Inno Setup Compiler. And everything worked fine. Until I gave the installer to a friend. He installed, but at startup he got an error: required MSVCP140.dll. I was told that the launch requires the installation of the package vc_redist140.

How to register that when installing the program, the installer installs the vc_redist140 package?

P.S. If there is another solution to the problem, I am ready to consider.

    1 answer 1

    So:

    [Run] Filename: {src}\Redist\vcredist_x86.exe; WorkingDir: {src}\Redist; Flags: skipifdoesntexist; 

    Even so, you can do:

     [Tasks] Name: redist\vc; Description: Microsoft Visual C++; Flags: checkablealone; [Run] Filename: {src}\Redist\vcredist_x86.exe; WorkingDir: {src}\Redist; Tasks: Redist\vc; Flags: skipifdoesntexist;