LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I configure my CVI 6.0 distribution kit to do similiar functionality as in V5.5

I want to incorporate the "ask to overwrite" option on install along with the uninstall.exe functions that are avilable with my older v5.5. Can I do this with version 6.0?
0 Kudos
Message 1 of 4
(2,938 Views)
Murray,

These options are no longer available in CVI 6.0, because the distribution kit is now utilizes Microsoft Windows Installer (also called MSI) - which has the many benefits of being a modern installer technology. Unfortunately, this change does require some behavior changes from earlier CVI versions.

I'm assuming that you're referring to the uninstall.exe that was previously placed in the applications folder in the start menu? The uninstall item is now available in the control panel under Add/Remove Programs, or you can just run the setup.exe again.

For the file replacement, the following is a summary of rules used by the CVI 6.0 distribution kit:

1. For files with a version resource - The file with the highest version wins, even if the existing file
on the machine has the highest version.

2. A versioned file will always get installed over a non-versioned file.

3. For files with no version resource - If the file has been edited, then do not replace the file. If the file has not been edited, then replace the file. (A file is considered "Edited" if the Modified date for the file on the machine is later than the Create date for the file on the machine).

These rules can be changed slightly by modifying the generated .MSI file using a MSI file editor, but it may not be straightforward if you're not familiar with MSI technology (see the CVI whitepaper entitled "Modifying Create Distribution Kit Installers in LabWindows/CVI 6.0", which is available in your CVI 6.0 distribution).

Regards,
- Wes / NI
0 Kudos
Message 2 of 4
(2,938 Views)
Thanks Wes,
I have had a look at the CVI white paper regarding .MSI and it still left me a little wanting. Any other reference to have a look at?
0 Kudos
Message 3 of 4
(2,938 Views)
Greetings Murray,

Well, the white paper basically describes what MSI is, what tools you can use to edit them, how to pull a CVI distribution kit .MSI into them, and where to read more about MSI after you do. The details of what you actually need to edit in an MSI to make a particular change is unfortunately well beyond what could fit in a white paper 🙂 (The commercial tools do help a lot in this area, though)

To get you started, though, you could create a property in the MSI Property table name "REINSTALLMODE". If the property isn't present, it's default value is "omus" (each character represents a particular installer behavior for file replacement). Here is a table from MSDN which describes other possible values:

p - Reinstall only if file
is missing (i.e., verify that the file is present).
o - Reinstall if file is missing, or an older version is present.
e - Reinstall if file is missing, or an equal or older version is present
d - Reinstall if file is missing, or a different version is present
c - Reinstall if file is missing, or corrupt. This option only repairs files that have msidbFileAttributesChecksum in the Attributes column of the File table.
a - Force all files to be reinstalled, regardless of checksum or version.
u - Rewrite all required registry entries from the Registry table that go to the HKEY_CURRENT_USER or HKEY_USERS registry hive.
m - Rewrite all required registry entries from the Registry table that go to the HKEY_LOCAL_MACHINE or HKEY_CLASSES_ROOT registry hive. Rewrite all information from the Class table, Verb table, PublishComponent table, ProgID table, MIME table, Icon table, Extension table, and AppID table regardless of machine or user assignment. Reinstall all qualified components
.
s - Reinstall all shortcuts and re-cache all icons overwriting any existing shortcuts and icons.
v - Use to run from the source package and re-cache the local package

Regards,
- Wes / NI
0 Kudos
Message 4 of 4
(2,938 Views)