-3

I am working on the Setup Project (msi installer package creator) of a C# desktop application in Visual Studio 2010. I want to add some product activation conditions based on radio buttons in the setup project. I have added a user interface in setup project containing the radio buttons, but i don't know where to get the selected value from this interface, or where is this selection stored. Image Radio Buttons User Interface

Shahrukh
  • 13
  • 2
  • 7
    Come on, please [google](https://www.google.de/search?source=hp&ei=5VAdWpWGHNDGwAKS7Z6gBw&q=get+selected+value+from+radio+button+c%23&oq=c%23+get+selecedt+value+form+ra&gs_l=psy-ab.3.1.0i22i30k1j0i8i13i30k1.893.10516.0.14636.34.30.2.2.2.0.163.1879.29j1.30.0....0...1c.1.64.psy-ab..0.34.1890...0j0i131k1j0i13k1j0i13i30k1j0i13i10i30k1j0i19k1j0i13i30i19k1j0i22i30i19k1j0i22i10i30i19k1j33i22i29i30k1.0.bN2Gh0l5nMY) this at least once. You will find your answer like 100% sure. ;-) – L. Guthardt Nov 28 '17 at 12:04
  • tried it, could you please provide some info or iink? – Shahrukh Nov 28 '17 at 12:29
  • No harm though, but is this a joke? The *google* word in my comment is blue. Doesn't this imply that this is a link? – L. Guthardt Nov 28 '17 at 12:34
  • no bro, i didn't mean that, they are mostly referring to asp controls,, I'm working with a setup project of a desktop app.. and what I was asking is that I need to see the code where the user interface selected values in the Setup project are, because i don't see any piece of code where these values will be stored,, sorry for the confusion – Shahrukh Nov 28 '17 at 12:47

1 Answers1

1

You can't run code on the button click of a dialog in a Visual Studio setup's MSI. Other tools (InstallShield, WiX, Advanced Installer etc) offer support for all Windows Installer functionality, but Visual Studio setups do not. Those tools let you run a custom action on a button click to validate the input, for example.

So your question is the nearly the same as these:

c# setup project get radio buttons value

How to code for Custom Dialog in Setup Project?

so basically you can pass the values to a custom action. However if you somehow want to change the course of the install based on the choice in the radio buttons there is not much you can do because all VS custom actions run at the end after everything is installed. It might be better to defer all this until the app first runs, and have the app deal with this. I assume that a user might want to upgrade from Demo to Student to Professional without re-installing the product.

PhilDW
  • 20,260
  • 1
  • 18
  • 28