thlucas
Posts: 10
Joined: Mon Feb 09, 2004 3:30 pm
Location: Omaha, NE
Contact: Website

Execute Temp File in Install Package from VBScript

Hi AI Support,

How do I include a temporary .EXE file in the install package (not installed, but in the .MSI) and execute it from a custom action VBScript?

What I am doing is running a VBScript which executes the .NET CLR GACUTIL.EXE utility to install some assemblys into the GAC. I want to execute the GACUTIL.EXE utility, but don't want to install it. I can't rely on the GACUTIL being in the .NET framework directory, and want to include it as part of my AI install package.

Note that I cannot use the Assembly functionality in AI, as I need to leave the assembly in the installed folder as well as in the GAC. This is a requirement of Visual Studio, in that the GAC copy is used when the application is running, and the installed copy is used by the VS IDE when designing an application that uses the assembly. The AI "Assembly Install" functionality removes the assembly from the install folder after it installs it into the GAC (ie move instead of a copy). I wish there was a flag in AI that controlled whether the assembly was moved or copied to the GAC from the install path - I requested this feature awhile back, but noone got back to me ...

Any ideas?

Thanks - Todd
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi,

I would suggest adding the assembly twice. Once with "Destination" set to "Install in Global Assembly Cache" and second with "Destination" set to "Private Install To".

This also involves including the assembly twice in the "Files and Folders" page in different folders.

Regards,
Gigi
__________________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com
thlucas
Posts: 10
Joined: Mon Feb 09, 2004 3:30 pm
Location: Omaha, NE
Contact: Website

Hi Gigi,

I could do that, but we are talking about @30 different assemblies I would need to add in both places. I currently add these in 1 VBScript file.

Any chance of adding the copy / move GAC install functionality in a future release of AI? :lol: I originally requested this feature on July 18, 2005 in the following post:

http://www.advancedinstaller.com/forums ... .php?t=649

Thanks,

Todd Lucas
AI Pro License since Jun 2005.
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi,

We add this on our TODO list and in a future version of AI you will be able to install the assemblies in both destinations (GAC and private location).

Regards,
Gigi
_________________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com

Return to “Common Problems”