I use Inno to install my applications, and I was seeing some messages at the Wikis and saw that some developers where using .msm files to install VFP 7.0 runtimes and other OCX files.
I decided to search at MS to understand what .msm files are and found this page
http://msdn.microsoft.com/vstudio/downloads/tools/vsi11/tour.aspthe page is about Microsoft Visual Studio Installer Guided Tour, and shows an VB example.
I discovered that I can use merge modules to share components and files among installer package files. As a single binary, a merge module delivers all the files, resources, registry entries, and setup logic required to install and use shared code.
And Windows Installer can help ensure that programs remain running even if core files are corrupted or deleted. With the Windows Installer, applications are self-repairing which means that they will reinstall necessary components without requiring the user to do anything.
So I decided to write the following in my script:
[Files]
...
Source: "C:\Program Files\Common Files\Microsoft Shared\Merge
Modules\Vfp7Runtime.msm"; DestDir: "{cf}Microsoft Shared\Merge Modules\";
CopyMode: normal
Source: "C:\Program Files\Common Files\Microsoft Shared\Merge
Modules\MSVCP70.msm"; DestDir: "{cf}Microsoft Shared\Merge Modules\";
CopyMode: normal
Source: "C:\Program Files\Common Files\Microsoft Shared\Merge
Modules\MSVCR70.msm"; DestDir: "{cf}Microsoft Shared\Merge Modules\";
CopyMode: normal
Source: "C:\Program Files\Common Files\Microsoft Shared\Merge
Modules\MSVCI70.msm"; DestDir: "{cf}Microsoft Shared\Merge Modules\";
CopyMode: normal
The problem is that the application file (.exe) isnt working.
Could someone explain-me why it doesnt work or what I'm missing, than I expected that those files copied to the station would enable that if the runtime is missing at the Windows/system dir it would be replaced automaticaly.
Thanks in Advance.
Peter