471,335 Members | 1,492 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,335 software developers and data experts.

Getting at actual install directory for .NET Setup

I developed a C# application which needs several data files. I want to
install them in a subdirectory of my install directory. In addition, I want
to set some registry strings to point to these files. I can get setup to
install the files fine. I can set the registry string values to the correct
paths if I use something like:

[ProgramFilesFolder][Manufacturer]\[ProductName]\WaveFiles\InvalidInput.wav

However, if, at the time of install, I specify a different directory then
the proposed default then this still sets my registry key to the c:\program
files... directory.

How do I set a registry string value from setup to contain the actual
location my location was installed too?

Thanks!

Grant Schenck
Dec 15 '05 #1
2 6246
Don't use the registry. Use a config file.

--

Derek Davis
dd******@gmail.com

"Grant Schenck" <sc******@optonline.net> wrote in message
news:OS*************@TK2MSFTNGP10.phx.gbl...
I developed a C# application which needs several data files. I want to
install them in a subdirectory of my install directory. In addition, I
want
to set some registry strings to point to these files. I can get setup to
install the files fine. I can set the registry string values to the
correct
paths if I use something like:

[ProgramFilesFolder][Manufacturer]\[ProductName]\WaveFiles\InvalidInput.wav

However, if, at the time of install, I specify a different directory then
the proposed default then this still sets my registry key to the
c:\program
files... directory.

How do I set a registry string value from setup to contain the actual
location my location was installed too?

Thanks!

Grant Schenck

Dec 15 '05 #2
Never mind... found it [TARGETDIR].

"Grant Schenck" <sc******@optonline.net> wrote in message
news:OS*************@TK2MSFTNGP10.phx.gbl...
I developed a C# application which needs several data files. I want to
install them in a subdirectory of my install directory. In addition, I want to set some registry strings to point to these files. I can get setup to
install the files fine. I can set the registry string values to the correct paths if I use something like:

[ProgramFilesFolder][Manufacturer]\[ProductName]\WaveFiles\InvalidInput.wav
However, if, at the time of install, I specify a different directory then
the proposed default then this still sets my registry key to the c:\program files... directory.

How do I set a registry string value from setup to contain the actual
location my location was installed too?

Thanks!

Grant Schenck

Dec 15 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by Craig D | last post: by
3 posts views Thread by RichG | last post: by
7 posts views Thread by p | last post: by
reply views Thread by dotnetprogrammer via DotNetMonster.com | last post: by
3 posts views Thread by =?Utf-8?B?WmlhbmdpIEpvbmVz?= | last post: by
3 posts views Thread by Jean-Marc Blaise | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.