LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Default path for distribution kit

I would like my distribution kit to install by default to a path that is on a drive other than c:. How do I set my distribution kit to do this?
0 Kudos
Message 1 of 11
(3,485 Views)
Hello,

Because you cannot know a priori what drives will be available on any given system that your distribution might be installed to, all installation locations are typically described using a symbolic base location (like Program Files directory, or Windows directory, or Windows Volume Root) and a relative path.  The system might not even have a C: drive; the symbolic locations are resolved to the proper drives and paths at installation time.  For this reason, the only way to guarantee a valid default installation path is to use these symbolic base locations.

It is possible to work around (read "hack") this limitation, but it requires that you do some post-build, hand-editting of the .msi installer file using a tool like Orca (comes with the Microsoft SDK, a free download).  If you think this is something you are interested in, I can explain what needs to be done.

Hope this helps.

Mert A.
National Instruments
0 Kudos
Message 2 of 11
(3,479 Views)
Mert A.,
 
   Please do, as we need to assure that nothing accidentally gets installed to the C: drive. Thanks.
 
Steve
0 Kudos
Message 3 of 11
(3,476 Views)
Actually, instead of hacking the MSI file. Is there a way to setup a custom symbolic base location for the station I need to install it on?
0 Kudos
Message 4 of 11
(3,476 Views)
Hi Steve,

In order to figure out what the best/easiest workaround is for you, it would be helpful to get a little more about what your needs are, and what version of CVI you're using. 

1. Which version of CVI are you using? If 8.0 or later, are you including any other drivers?  If so, the situation may be complicated by the location of your National Instruments directory.

2. You mentioned that you want to assure that nothing gets installed to the C:\ drive.  Is it sufficient to change the default installation directory, or does it concern you that the user can still change this path to some directory on C:\ at install time?

3. Do you know for certain that all your target machines have a particular drive letter?

Mert A.
National Instruments
0 Kudos
Message 5 of 11
(3,467 Views)
I am using version 7.1. It is sufficient to just change the default directory.
0 Kudos
Message 6 of 11
(3,459 Views)
All machines have this drive letter that I am trying to use.
0 Kudos
Message 7 of 11
(3,458 Views)
In this case, I would recommend just setting the default installation path via a command line argument to setup.exe:

>> setup.exe INSTALLDIR=E:\

Replace "E:\" with whatever path you want.  You can create a batch file or other script to run instead of directly running setup.exe.

The other option would be to create a custom action (in the .msi's CustomAction table) and add a call to that custom action in the InstallUISequence and InstallExecuteSequence tables.  You could create a simple merge module to do this, then add the module to your distribution kit via a specially-named file group. The module will get merged into the .msi when the distribution is built.

If for whatever reason you don't want to use a script, I can create the merge module for you (just tell me what default path you want) and tell you how to add it to your distribution kit.

Hope this helps.

Mert A.
National Instruments
Message 8 of 11
(3,455 Views)
Getting closer. How would I create a r:\StationSoftware merge module?
0 Kudos
Message 9 of 11
(3,453 Views)
Is there anyway to set this directory in the setup.ini file?
0 Kudos
Message 10 of 11
(3,453 Views)