cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
danobrega
Level 2

InstallUtil, version

My setup includes a .Net windows service. I selected ".Net Installer Class:Yes" on my component configuration.

After this step my setup started failing with error 1001. After a few searches I found out that I had to select the correct version of InstallUtil by typing the correct path in Tools->Options->.Net.

Now, in my setup I have a .Net 4 windows service, so the correct path seems to be C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319. After I changed this my setup was working again.

Now, here's what I think is wrong with this approach:

1) I may be installing different components that require different .Net versions.
2) .Net path may differ from machine to machine.

It would be desirable for install shield to inspect the component dll, see what version of .Net it requires and automatically run the correct InstallUtil from its install directory. The install directory should be discoverable by inspecting windows registry.

Regards,
danobrega.
Labels (1)
0 Kudos

(1) Reply
Christopher_Pai
Level 16

Take it from me, you don't really want to use InstallUtil period. Google for DTF ( Deployment Tools Foundation ) including articles on my blog. One of the many superior things that it does is allow you to specify the supported runtimes via an xml tag.

One of the many horrible things about InstallUtil that you may not be aware of is if you have multiple CA's in your installer the very first one will tatoo the msiexec process with the CLR version. The next CA to fire would be forced to use that CLR version. DTF solves this ( and many other ) problem by running only unmanaged code inside the msiexec process and using RunDll32 to create another process for hosting the CLR. It also has a remoting mechanism that allows your CA to be able to use the MSI handle to query the database, read/write properties and post messages to the log ( all things that InstallUtil is unable to do ).
0 Kudos