Search code examples
c#visual-studio-2010windows-installercustom-action

Can I somehow get values entered in the User Interface into my custom actions installer class code?


This seems like it should be pretty simple. I have a Windows installer project. Inside the UI, I added a dialog with 2 radio buttons. The installer has a custom action on 'Install' which uses an install class from the primary output of one of my projects. Is it possible to get the value of the selected radio button from within the Install method in the installer class?


Solution

  • To get/set a property you need an MSI handle which, from what I know, you cannot obtain from a .NET Installer class custom action.

    What you could do is to configure the custom action to accept new parameters, and assign the value of your property to those parameters, when configuring the custom action.