Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

.net Setup Project: How to pass multiple CustomActionData fields

In a .net "Setup Project", it is possible to add one or more custom screens in the setup wizard, with fields (e.g. text boxes) where the user can enter additional installation parameters.

A custom field can then be passed to a "Custom Action" class library project, to handle the user field. The image below shows how the property "ServerName" gets mapped to the EDITB1 text field:

enter image description here

Within the Custom Action class, the property is accessed as follows:

string serverName = Context.Parameters["ServerName"];

Question: how can one specify multiple properties (for multiple text boxes) to the Custom Action?

like image 701
byneri Avatar asked Nov 03 '11 18:11

byneri


1 Answers

As per the documentation for CustomActionData regarding passing multiple values:

Multiple values must be separated by a single space: /name1=value1 /name2=value2. If the value has a space in it, it must be surrounded by quotation marks: /name="a value"

like image 75
Reddog Avatar answered Nov 04 '22 20:11

Reddog