cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
asr105
Level 3

Setting the Version of Feature and Product in Runtime

I am using IA 8.0 EE.

I have a requirement in which I need to set the version of a Feature and the Product during run-time.

The options I looked at were:
1. Standard IA variables - Could find any variables which can set the version. PRODUCT_VERSION_NUMBER is read-only.
2. APIs - I could not find any APIs which would enable setting the versions during run-time.
Labels (1)
0 Kudos
(3) Replies
pv7721
Level 20

I don't think it's possible... the feature and product information must be set before running the installer. Setting them at runtime would be done based on what criteria?!?
0 Kudos
asr105
Level 3

You had asked, 'Setting them at runtime would be done based on what criteria?!?'. I don't quite understand the criteria but I will describe the problem.

We have observed that, sometimes, the IA registry file doesn't get updated with the Product entries on Installation. We rely on the IA registry to determine if it is an install, reinstall or an upgrade.

In a machine, where the IA registry is corrupt (in our case, empty), one way forward would be 'patch' the IA registry. To do this, an idea was to invoke an IA-based installer (which would act as a patch) this would take in the version as the input and set the feature and product version and complete the installation. Once the patch/installer completes, the IA registry would be updated with the required values (or so we think).

The obstacle we are facing is that we do not know how to set version in runtime.

Why are we doing this?
To patch the IA registry.
Why patch the IA registry?
To detect the type of install as an install, reinstall or an upgrade more reliably.
0 Kudos
pv7721
Level 20

I'm not sure if you can "play" in this way with the registry. What would work best I guess, if it's on Windows, is to have your installer write a fixed key (including the version for instance) that is to be removed by the uninstaller. This way the install can start by checking for the presence of the key, and act accordingly: if the key is present, it's a reinstall / upgrade, if not it's a fresh install.
0 Kudos