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

Setting product version in Registry in BasicMSI

Hi,

I am making a BasicMSI installer for one of our applications. I want to get the version string of the product being installed so that i can save it in one of the Registry keys.

This might seem like a very stupid question to ask but i can tell even in my sleep that the string "IFX_PRODUCT_VERSION" in an InstallScript function will give you this value. But i m completely BasicMSI illiterate.

Please help!:(
Labels (1)
0 Kudos
(2) Replies
kriz_82
Level 5

One way is to use value of the same system viariable (IFX_PRODUCT_VERSION) in Basic MSI. Just create CA of IS type and check the value.
Another option is to read msi property 'ProductVersion'.

STRING sVer;
NUMBER nSize;

nSize = MAX_PATH;
MsiGetProperty(hMSI, "ProductVersion", sVer, nSize );
MessageBox("ProductVersion: " + sVer, INFORMATION);

Regards!
0 Kudos
RobertDickau
Flexera Alumni

You could also use [ProductVersion] in one of the registry views, and the value will be expanded at run time.
0 Kudos