|
Hi,
I made simple winform application in C#. I am showing menu options depending upon the mode selection. .i.e. if mode is eng then I am showing all the menus in MDI and if mode is tech then I am hiding some menus of MDI.This is handled in Code.
I am using MSI to create setup.I am using custom dialog box i.e. 2 radio button for mode selection. Now I want install software depeding upon the mode selection. i.e. if I select Eng mode radio button then installer install software with all menus and if I select tech mode then installer install only few menus which is applicable to tech mode.
I dont know how to use custom action so that i can pass the selection option to the exe.
Is there any other solution just let me know.
Thanks,
sjs4u
|
|
|
|
|
sjs4u wrote: I dont know how to use custom action so that i can pass the selection option to the exe.
So the "mode" (eng/tech) is passed as a command-line parameter? I think you could add that part in the shortcut that's being made.
Alternatively, you could write a setting during the custom action[^] and check it's value on startup.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Hi Eddy,
Thanks for your reply.
Yes I am passing tech/eng mode values as commadline argument and checked that in Main Method in program.cs. Default is tech mode.
In Installer Project - I set the radio button values and can able to get these values using
string myInput1 = this.Context.Parameters["BUTTON1"];
string myInput2 = this.Context.Parameters["BUTTON2"];
Now when I start installer it is showing 2 radio button and in that i want selected radion button value to be passed to exe so that only that exe get installed.
Regards,
sjs4u
|
|
|
|
|
sjs4u wrote: Now when I start installer it is showing 2 radio button and in that i want selected radion button value to be passed to exe so that only that exe get installed.
Most installers will allow you to create a "default" and a "custom" setup; simply install a different shortcut on the desktop, and put the argument in there.
"How" that's done will vary per installer; check it's manual.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|