I have a non-standard feature in my installer, which doesn't contain any installable files, but triggers a custom action instead. As this feature doesn't contain any official file components, the installer displays 0 as the required disk space for this feature. How can I set the cost of a feature manually in WiX?
WiX: Manually set the cost of a feature
Asked Answered
The installer correctly displays 0: the feature would not take any disk space once the product is installed. –
Feldspar
The feature would take quite a few megabytes. The fact that there are no official components doesn't mean that no files are copied, this happens in a custom action (why - don't ask, long story). –
Caecilian
I don't think it's possible to manually set the size of a feature. Your approach kinda does it the wrong way from Windows Installer's point of view. You should add all the files installed by your custom action to the MSI database so that the MSI engine installs them and knows about them. Then you run your custom action (the modified version of course) to perform any post-processing if it's necessary at all. You should really avoid installing any files by means of custom actions. –
Feldspar
You can use the ReserveCost element to associate additional cost with one of your Component
elements. You will need to have at least one Component
in the install to associate with Feature
.
© 2022 - 2024 — McMap. All rights reserved.