Solved

How do I create a dependency installer in VB6

Posted on 2010-08-29
7
893 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
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

 
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

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

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…
Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
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…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

789 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