Results 1 to 5 of 5

Thread: [RESOLVED] Create VB6 App Installation Package to install on latest Win OS's

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Nov 2010
    Posts
    220

    Resolved [RESOLVED] Create VB6 App Installation Package to install on latest Win OS's

    I have a very old vb6 application that I need to create an installation package so a user can install on his system.

    I've used InnoSetup for another vb6 application and it worked great.

    But for another vb6 app, I keep getting installation errors and I know it is because I don't know how I'm suppose to install/register (or not) certain DLLs and such.

    And I don't know if InnoSetup is the best way to go either.

    How do you know what special treatment each DLL or OCX requires or where it needs to go?

    Is there simple tool or something that will quickly tell me what DLLs or OCXs I need to package, and where it needs to go on the system, and whether it needs to be registered or not?

    Rich

  2. #2
    PowerPoster
    Join Date
    Feb 2006
    Posts
    22,825

    Re: Create VB6 App Installation Package to install on latest Win OS's

    No-no Setup requires you to know everything and get it all very close to exactly right. And even then you risk breaking other applications, especially if the user ever uninstalls yours.

    It is concentrated evil in all but the most careful expert hands.

    While there are newer technologies today, I believe the best one for VB6 programs is still base on Windows Installer technology. For the VB6 OCXs Microsoft even provide merge modules yet. Those have most of the necessary "intelligence" built in.

    Of course you still should know which OCXs your program uses, and for 3rd party OCXs (or your own) you may find yourself left to your own devices yet. These should normally always come with a .DEP file describing things like where to install it.

    The old PDW can be used safely, but only if it can read an updated VB6DEP.INI, which is a sort of "global .DEP file" that it tries to use when it can't find a specific .DEP file for a library. Updating VB6DEP.INI is your responsibility, and you might need several of them if your program targets downlevel systems like Win9x as well as OSs from Vista onward. That's because conditions changed over time. What to update in there largely comes from reading 20+ years worth of MS KB articles.

    But at least the PDW is smart enough about checking for existing copies of things and about unstalling properly - unlike the No-no.


    This is part of why Microsoft dropped Standard (home game) Edition when VB6 was released. VB6 is only meant for professional use, much like VC++.

    It's also why they moved on to .Net where they could avoid the hazards to the OS they encountered when the great unwashed used VB5. The vast majority of .Netters seldom use anything but ClickOnce deployment which is well sandboxed.

    Windows now fairly aggressively protects itself, but it can't do very much about protecting other applications from the No-no or similar legacy scripted setup packages.


    Some VB6 applications can also use private assemblies to isolate their dependencies. That doesn't help if you have any ActiveX EXE's, but aside from that it might be safest. Not only does it protect you from No-no Setups running roughshod all over the filesystem and registry, it also makes simple XCopy Deployment possible.

    Then your installer only has to unpack the files into a destination and create Start Menu shortcuts and stuff. The downside is that uninstallation via Control Panel isn't supported without extra work. It can still be done, but few bother.

  3. #3
    PowerPoster wqweto's Avatar
    Join Date
    May 2011
    Posts
    3,281

    Re: Create VB6 App Installation Package to install on latest Win OS's

    For any Windows past XP you just want to use regfree COM so that your VB6 apps can be used as portable ones so called XCopy deployable.

    After this use InnoSetup just to copy the files to a custom folder and create shortcuts - no registration, no touching system32 and you get uninstall for free.

  4. #4

    Thread Starter
    Addicted Member
    Join Date
    Nov 2010
    Posts
    220

    Re: Create VB6 App Installation Package to install on latest Win OS's

    Quote Originally Posted by dilettante View Post
    No-no Setup requires you to know everything and get it all very close to exactly right.
    It took me to read half your comment to realize what you meant by "no-no setup". LOL! Tell me how you really feel about InnoSetup. :-)

    I recall some many years ago that when I was writing VB6 apps (part-time...as a non-professional obviously) that I changed to InnoSetup because seemed liked a nice quick way to churn out installs once the script was customized to the app. I do remember I wasn't a fan of the PDW but don't recall why.

    In recent weeks I've returned to my old VB6 IDE (after much grief in making things work in Windows 10) to make certain changes and updates/old bug fixes to apps that have been in use since the early 2000's and this has meant that I have to RELEARN VB6 all over again (of course some of it quickly came back to me, like the syntax formatting, etc.) and the logic behind these apps.

    I was in my late 30's and early 40's when I wrote these applications. I'm now 62!

    So this is why my posts have just started popping up in recent weeks after a multi-year hiatus. And I hope this explains why someone who wrote in VB4 to VB6 back in the 1990's and beyond is still asking very NOOB questions. Because I am one!

    When it comes to HOW these VB6 apps deal with dependencies, install packaging, etc. I'm really in the dark.

    I really do appreciate your comments and get a little smarter from each one of them. Thanks!

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Nov 2010
    Posts
    220

    Re: Create VB6 App Installation Package to install on latest Win OS's

    Quote Originally Posted by wqweto View Post
    For any Windows past XP you just want to use regfree COM so that your VB6 apps can be used as portable ones so called XCopy deployable.

    After this use InnoSetup just to copy the files to a custom folder and create shortcuts - no registration, no touching system32 and you get uninstall for free.
    I will have to dig into subject of RegFree COM some. I'm happy to learn that several of those dependencies in my old Inno install script no longer needs to be in there as they are part of modern Windows OS's.

    And I have NO PROBLEM with leaving Win XP behind. Those currently using my app are well past that OS anyway.

    Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width