Making the MSI installer with VS.NET2003 Follow the user selection to write different registry values

xiaoxiao2021-03-06  88

I don't know if I can program the added interface elements when making installations. Of course, I don't want to write a configuration application. The problem encountered a few days ago is that a software installer needs to be different in accordance with the user selection of the installation type, and write different values ​​in a registry. At present, I know that the value of the elements of the installation interface can be used for conditions. The added interface is to let the user choose the home version or the office, if it is a home version, write the registry softversion = 100, if it is the office, write the registry softversion = 200. First, we add a dialog box in the user interface of the installation project -> Installation -> Start, I select Radiobutton (two buttons), change Button1Label to the home version, button2label change to office, where Button1Value = 1, Button2Value = 2, ButtonProperty = Button2 (This is used as condition judgment), defaultValue = 1 (the value selected by default). Then create two keys in the installation engineering registry:

SoftVersion = 100, (Condition property) Conditions set to Button2 = 1

SoftVersion = 200, (Condition property) Conditions set to Button2 = 2

Then compile the installation, the installer will be different depending on the version of the installed installation, and write different values ​​in the registry.

转载请注明原文地址:https://www.9cbs.com/read-122294.html

New Post(0)