Setup and Installation Project
-
Hi, I have an application for which I must create a Setup package. The package allows the user to enter some information in a text box (during the installation). I have used Textboxes(A) for this purpose. The textbox must contain a default value when presented to the user during the installation. This default value must be set dynamically. Is there some way this can be done... maybe the Setup Package reading an ini file and putting the value from the file into the text box during the installation? I don't know if and how ini files can be read during the installation.
-
Hi, I have an application for which I must create a Setup package. The package allows the user to enter some information in a text box (during the installation). I have used Textboxes(A) for this purpose. The textbox must contain a default value when presented to the user during the installation. This default value must be set dynamically. Is there some way this can be done... maybe the Setup Package reading an ini file and putting the value from the file into the text box during the installation? I don't know if and how ini files can be read during the installation.
You set the
Edit_N_Property
to a property name, typically upper case (so it can be changed on the command-line as a protected property, though, IIRC, VS.NET doesn't use this (it's very limited in functionality when it comes to Windows Installer packages). You can set the initial value usingEdit_N_Value
. After compiling the MSI package, you can also use Orca from the Windows Installer SDK (go to http://msdn.microsoft.com/platformsdk[^] to download it, though Orca is a separate install within the downloaded files; in the bin directory, install Orca.msi) to add that same property name to the Property table with the initial value.Microsoft MVP, Visual C# My Articles
-
You set the
Edit_N_Property
to a property name, typically upper case (so it can be changed on the command-line as a protected property, though, IIRC, VS.NET doesn't use this (it's very limited in functionality when it comes to Windows Installer packages). You can set the initial value usingEdit_N_Value
. After compiling the MSI package, you can also use Orca from the Windows Installer SDK (go to http://msdn.microsoft.com/platformsdk[^] to download it, though Orca is a separate install within the downloaded files; in the bin directory, install Orca.msi) to add that same property name to the Property table with the initial value.Microsoft MVP, Visual C# My Articles
I already have used the Edit1Property and have set it to "URL". What I need is to be able to fill the Edit1Value dynamically, read from a text file maybe, and be displayed to the user. Think of it as evolution in action
-
I already have used the Edit1Property and have set it to "URL". What I need is to be able to fill the Edit1Value dynamically, read from a text file maybe, and be displayed to the user. Think of it as evolution in action
You have to write a custom action for that, and writing a .NET
Installer
class derivative won't work. You must write a native custom action (see the Windows Installer SDK for details), and VS.NET does not support that. It can be read from the command-line, though, if you use something like this:msiexec.exe /i MyPackage.msi URL=http://www.codeproject.com
I suggest you read through the Windows Installer SDK. The VS.NET Windows Installer project is very limited, as I mentioned before. Trust me - I've been working with Windows Installer since 1.0 beta many years ago and have been a consultant for numerous companies for Windows Installer-related development. VS.NET's Installer project is meant to be quick and simple and does not expose a UI for a majority of what's possible.
Microsoft MVP, Visual C# My Articles