Thanks for Kevin's input.
Hi Steve,
I think what you want is doable through the VS 2005 setup project. Here are
some approaches you can consider:
1. There are plenty of built-in and context related propeties in windows
setup/installer sdk. And such properties can also be used in VS setup
project(since the setup project provide a sub set of what windows installer
sdk provides).
#Property Reference
http://msdn2.microsoft.com/en-us/library/aa370905.aspx
And for the installation folder(main folder) the user choose at runtime,
there is a corresponding property named "TARGETDIR". So you can get the
main install folder of the installing program in your setup project.
#TARGETDIR Property
http://msdn2.microsoft.com/en-us/library/aa372064.aspx
You can directly use this property in the VS setup project's registry
editor(pass the property name into the certain registry item's value) e.g.
value: [TARGETDIR]\
#Properties for the Registry Editor
http://msdn2.microsoft.com/en-gb/library/bbxyfa24(VS.80).aspx
2. The above one may be quite limited when you want to add more values
derived from the built-in properties(in windows installer). For example,
you may want to concatenate the propety with other values. Then, you can
consider creating a custom Action to do the work. You can pass those
context or built-in properties in to your custom action and use those
properties in your own code. Here are some good reference introducing using
custom action and pass data into it:
#Walkthrough: Using a Custom Action to Display a Message at Installation
http://msdn2.microsoft.com/en-us/library/9cdb5eda(VS.80).aspx
#Visual Studio Setup - projects and custom actions
http://www.simple-talk.com/dotnet/vi...setup---projec
ts-and-custom-actions/
Please let me know if you have anything unclear. If you feel necessry I can
send you a very simple setup project demo on this.
Sincerely,
Steven Cheng
Microsoft MSDN Online Support Lead
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.