VB6 and Setup.exe distribution package deployment
Posted on 2006-05-29
I had a few questions answered yesterday about creating packaged setup.exe files for VB6 projects. But one still remains confusing!!!
I am grateful for the guidance I have received thus far but I think one part was incorrect.
I was told that I should distribute my VB application with all of the most recent xxxxxx.dll files. After reading the Microsoft article ID 830761 it appears that the strategy is to first look in the VS6 ‘redist’ folder for DLLs to distribute then if not found it gets them from the system directory. This means that all redistributable files provided WITH Visual Basic 6 for redistribution should be used. If the dll / ocx files required to include are not supplied by Visual Studio then they are selected from the System32 directory.
PLEASE answer this question only if you KNOW the answer.
Are VB applications compiled using the dll’s in the system32 directory(most likely) or from the Visual Studio redist directory (less likely I think)?
SO, if the compiled .exe program uses the system32 DLL’s, am I REALL OK distributing the older DLL’s with it? I am an embedded systems engineer so this windows magic seem odd. Does the linker really know where to call the functions / objects in the DLL or is it handled with some win magic that I don’t have to worry about (i.e. run time binding or some other form of DLL management)
This would mean that I package my freshly compiled EXE with the following dll’s from VS6 SP6 redist folder.
These files are from the redist folder (in my case)
C:\Program Files\Microsoft Visual Studio\VB98\Wizards\PDWizard\Redist
ALL OF THESE FILES ARE OLDER than the current system32 dll’s on my machine.
Asycfilt.dll 2.40.4275.1 144 KB (147,728 bytes)
Comcat.dll 4.71.1460.1 21.7 KB (22,288 bytes)
Msvbvm60.dll 126.96.36.199 1.32 MB (1,386,496 bytes)
Oleaut32.dll 2.40.4275.1 584 KB (598,288 bytes)
Olepro32.dll 5.0.4275.1 160 KB (164,112 bytes)
Stdole2.tlb 2.40.4275.1 17.5 KB (17,920 bytes)
And according to Microsoft article ID 197580, I should also use (from the same folder) the
RICHED32.DLL 4.0.993.4 174,352 bytes
However, I also need to distribute the following ocx’s with my application…
I can only find these ocx’s in the active system directory C:\WINDOWS\system32 directory.
(Note: ALL of the above files are on the Microsoft ‘OK to redistribute’ list ‘redist.txt’.)
FYI: I ran a test and this, in fact, appears to be the scenario created by the Packaging and Distribution wizard.
It just seems weird that I am using some older DLL’s included in my distribution package even though I compiled (or so I would think) with the newer ones. By the way,
IF YOU DON’T KNOW please don’t guess! (or at least tell me you are just guessing) I really need an answer from someone who knows if this DLL distribution schema is really correct. And If not, what is…