Solved

How do I create a dependency installer in VB6

Posted on 2010-08-29
7
891 Views
Last Modified: 2012-05-10
Is there a simple way to create an installer that just installs all the dependencies of a VB6 project without installing the actual exe file. Preferably not starting a blank installer project and manually adding every dependency.
0
Comment
Question by:esiexc
  • 2
  • 2
  • 2
  • +1
7 Comments
 
LVL 2

Assisted Solution

by:hilltop
hilltop earned 100 total points
ID: 33555587
I have always like NSIS. http://nsis.sourceforge.net/Main_Page 
Would you like a NSIS example?
0
 
LVL 14

Accepted Solution

by:
VBClassicGuy earned 150 total points
ID: 33555939
I know what you mean. Your situation may be like mine. I write and manage a suite of 26 programs. All programs use the same dependencies, third-party components, etc. These "system files" as I call them make a fairly large install file using Wise Installer. The program installations themselves are smaller than the system files installation. Since the system files change rarely (only when I add another component), I provide my users with a main "setup" installation, then they can download the smaller program(s) they need. In other words, I don't want to bloat 26 installations with a bunch of "system files",so I make that a separate installation.
You should be able to do this with just about any installer...make a full install but leave out the actual compiled exe. If you can't with your installer, many installers generate a script that the install program reads upon startup. Just edit that script by hand after it is created and delete the line that installs the program itself.
Did any of that make any sense? It's late at night...
0
 

Author Comment

by:esiexc
ID: 33558662
I use the visual basic package and deployment wizard.

I will try and edit the script and see if that works or not and post what I find out.
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 
LVL 14

Expert Comment

by:VBClassicGuy
ID: 33561175
I've never used the package and deployment wizard, so what I say next may or may not apply.
Make sure when you delete the script line that installs the program itself, that you also remove any lines that reference the exe, add it to the Start menu, make a desktop shortcut, etc.


0
 
LVL 2

Expert Comment

by:hilltop
ID: 33562094
I would use NSIS to make the setup file.
http://nsis.sourceforge.net/How_to_install_the_VB6_runtimes

This would do the trick
 !include Library.nsh
Section "-Install VB6 runtimes"
 !insertmacro InstallLib REGDLL $ALREADY_INSTALLED REBOOT_NOTPROTECTED "msvbvm60.dll" "$SYSDIR\msvbvm60.dll" "$SYSDIR"
   !insertmacro InstallLib REGDLL $ALREADY_INSTALLED REBOOT_PROTECTED    "oleaut32.dll" "$SYSDIR\oleaut32.dll" "$SYSDIR"
   !insertmacro InstallLib REGDLL $ALREADY_INSTALLED REBOOT_PROTECTED    "olepro32.dll" "$SYSDIR\olepro32.dll" "$SYSDIR"
   !insertmacro InstallLib REGDLL $ALREADY_INSTALLED REBOOT_PROTECTED    "comcat.dll"   "$SYSDIR\comcat.dll"   "$SYSDIR"
   !insertmacro InstallLib DLL    $ALREADY_INSTALLED REBOOT_PROTECTED    "asycfilt.dll" "$SYSDIR\asycfilt.dll" "$SYSDIR"
   !insertmacro InstallLib TLB    $ALREADY_INSTALLED REBOOT_PROTECTED    "stdole2.tlb"  "$SYSDIR\stdole2.tlb"  "$SYSDIR"

 SectionEnd

 Section "-un.Uninstall VB6 runtimes"

   !insertmacro UnInstallLib REGDLL SHARED NOREMOVE "$SYSDIR\msvbvm60.dll"
   !insertmacro UnInstallLib REGDLL SHARED NOREMOVE "$SYSDIR\oleaut32.dll"
   !insertmacro UnInstallLib REGDLL SHARED NOREMOVE "$SYSDIR\olepro32.dll"
   !insertmacro UnInstallLib REGDLL SHARED NOREMOVE "$SYSDIR\comcat.dll"
   !insertmacro UnInstallLib DLL    SHARED NOREMOVE "$SYSDIR\asycfilt.dll"
   !insertmacro UnInstallLib TLB    SHARED NOREMOVE "$SYSDIR\stdole2.tlb"

 SectionEnd

Just copy yur runtimes to into the same directory as the .nsi script. I would dress the installer as well.
0
 
LVL 3

Expert Comment

by:Genetic_Wolf
ID: 33613059
MOST Vb6 program only need 1 DLL.  in French, it's VB6FR.DLL and it doesn't need to be registered.
that mean most of my App are simply installed with a BATCH file to Copy, 2 files.

The MyProgram.EXE
and the Vb6Fr.Dll in the system32  (wich is easy to locate with a batch file, no matter what OS is installed)

not sure if the file is called Vb6EN.dll in english, but you whould be enable to spot the file in your Vb6 Install Wizzard.
0
 

Author Closing Comment

by:esiexc
ID: 33784161
I choose both solutions since I did not specify originally that I was using the vb6 packaging and deployment wizard.
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question