1.) For the installer, custom script (a batch file) was used to register the included libraries (regsvr32 /s "C:\WINDOWS\system32\sapi.dll").
Next, they run the custom script to install the type libraries into the assembly ("gacutil.exe" /i sapi.dll /silent).
I found a Microsoft link which states that the gacutil should only be used for development purposes, and the Windows Installer should be used for production assemblies.
QUESTION: Is there built in functionality within Advanced Installer to register and install libraries without using custom script or gacutil? I have included the batch file’s text below. If you could be very specific it would be very much appreciated.
Code: Select all
@ECHO OFF
:: Patch Internet Explorer 7 for the VB6 application browser
ECHO Registering IE components...
regsvr32 /s "C:\WINDOWS\system32\shdocvw.dll"
regedit /s "explorerPatch.reg"
:: Register the included libraries
ECHO Registering necessary libraries...
regsvr32 /s "C:\WINDOWS\system32\FM20.dll"
regsvr32 /s "C:\WINDOWS\system32\ccrpTmr6.dll"
regsvr32 /s "C:\WINDOWS\system32\Xvoice.dll"
regsvr32 /s "C:\WINDOWS\system32\Toolbar2.ocx"
regsvr32 /s "C:\WINDOWS\system32\Activelock3.6.dll"
regsvr32 /s "C:\WINDOWS\system32\sapi.dll"
:: Use the VSTA tools to generate an application Registry Hive
FOR /F "usebackq tokens=2* Skip=2" %%I IN (`reg query "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VSTA\9.0" /v InstallDir`) do SET VstaPath=%%J
ECHO Registering VSTA host components (this might take up to 5 minutes)...
call "%VstaPath%\vsta.exe" /HostID Hiatronics /setup
SETLOCAL
:: Install the type libraries into the Assembly (/silent)
ECHO Registering assemblies...
"gacutil.exe" /i sapi.dll /silent
"gacutil.exe" /i ccrpTmr6.dll /silent
"gacutil.exe" /i VSTA2_Integration.dll
"gacutil.exe" /i MyProgram.dll
ECHO Done!Code: Select all
::@ ECHO OFF
call "Utilities\gacutil.exe" /u VSTA2_Integration.dll /silent
call "Utilities\gacutil.exe" /u MyProgram /silent
call "Utilities\gacutil.exe" /u ccrptmr6 /silent
call "Utilities\gacutil.exe" /u sapi /silent
reg delete "HKLM\Software\Microsoft\VSTAHost\MyProgram" /f
rmdir /s /q "%HOMEPATH%\My Documents\MyProgram"
rmdir /s /q "%PROGRAMFILES%\My Program Development
FOLLOW US
Get the latest news in Application Packaging