So if you don’t know it, the technical preview version of Windows 10 is available. Being the good maintenance guy, you’ll want to know about installing VB6 on Windows 10. This article shows how I got it running on Microsofts latest OS.
I won’t run down the list of getting Windows 10 installed. If you’re able to grab the ISO, you should be able to get it running, I think. It’s pretty straightforward, as far as OS installs go. For this session, I’ll be using the Visual Basic 6.0 Enterprise Edition setup media.
Test System Configuration
The test system is a Hyper-V virtual machine, containing 2 processors, 8 GB RAM, and a 50 GB system drive. The OS is Windows 10 Technical Preview for Enterprise, Build 9841.
Stop the Reboot
As in my previous tutorials for installing VB6 on Windows 7 and Windows 8, you’ll want to create a zero byte file called MSJAVA.DLL. Creating this file in C:\Windows will prevent the need for a reboot at the end of the installation. If you’re not familiar with how to create a zero-byte file, just click that link back there.
Let’s Get Started
The first thing that you’ll notice after inserting your installation media is the Program Compatibility Assistant popping up with a warning of known compatibility issues. Close it – we need to run setup manually. If you have autorun turned off, you’ll get this pop up when you run setup.
Navigate to the installation media, and find the setup program. Right click setup.exe, and select Run As Administrator. Very important! Setup needs to do some registry twiddling and register some items with Windows, and won’t be able to do it without the necessary permissions.
Simply click the option that reads Run the program without getting help, and the main setup wizard will start.
The first few screens are the usual stuff, things you’ve seen before:
- Welcome Screen – Gives you the opportunity to vew the readme. Just click Next unless your really want to read it!
- EULA – Yep, it’s the End User License Agreement. Scroll it, then signal your acceptance in the appropriate radio button, then click Next.
- Product Number and USer ID – This is where you put in your user name, company name and product ID. Fill in the fields as you see fit, and click Next to continue with the wizard.
- What to install – Two options here; VB6 Enterprise Edition, or Server Applications. I am going with the first option
- Common Installation folder – I accepted the default for this: C:\Program Files (x86)\Microsoft Visual Studio\Common
- Welcome and Warning – Copyright protection, inability to update files in use, etc. Click Continue to move on
- Visual Basic 6.0 Enterprise Setup – This is where the actual installation of VB6 begins. Your PID is shown on the screen, and you are invited to write it down if you have not already. Click Ok to continue
Main Installation
On the first screen of the ACM Setup, leave the installation folder at the default, and click the Custom option for setup. The next screen will be the options list.
I don’t use SourceSafe, so I cleared the checkbox. If you use SourceSafe, then by all means leave it checked for installation.
Very important – Clear the checkbox for Data Access. If you don’t, set up will hang at the end of the installation. Not sure for the real reason, but the theory is that setup is trying to register with Windows on a non-existent service. Clearing the Data Access checkbox stops this registration attempt.
Click Continue to carry on with the installation process. At this point, if you didn’t create the empty MSJAVA.DLL file in C:\Windows, you’ll get a restart Windows prompt. Go ahead and restart if you need to, I’ll wait.
In any event, you’ll get an MSDN installation wizard. I decline this, since much more information is available online anyway.
Now you’ll get an option Server Setups dialog. If you want to install BackOffice, Visual SourceSafe Server, or SNA server, you have the opportunity at this point. I don’t use these items, so I just click Next to blow by it.
Finally, we get to the last screen of the wizard. Un-check the Register Now checkbox, and click Finish.
Getting VB6 Running for the First Time
You can find the new shortcuts in your start menu, under the usual Microsoft Visual Basic 6.0 program group. You might be tempted to just fire it up straight away, and you can. But, you’ll receive a nasty error about Automation, Error accessing the registry. You can blow by the error, but you’ll just keep getting it every time you fire up VB6, and some data-access related items won’t work correctly.
So, to get past this behavior, right-click the Microsoft Visual Basic 6.0 program icon in the start menu group, and select Run As Administrator. Click Yes in the resulting UAC dialog, and VB6 will start normally, presenting the new project wizard.
Ok, the first post-setup task is complete. Now on to the final piece.
Fixing the IDE Chug
Now before you start building a new project or editing an existing one, there is one more bit of configuration you might need to do. In running the IDE in a Windows 10 virtual machine, I’ve found that the IDE is somewhat sluggish when sizing and/or placing controls on a form, as well as sizing the form itself. This problem also presented itself in Windows 7 and Windows 8. We need to configure a couple things about the run properties of the IDE to fix this.
Be sure the IDE is closed, then right-click the start menu icon again. This time select Open file location.
In the explorer window that appears, right click the Microsoft Visual Basic 6.0 icon, and select properties. In the Properties window, select the Compatibility tab. On the Compatibility tab, click the Change settings for all users button.
In the new VB6 Properties window, place a tick mark in the Run this program in compatibility mode for: checkbox, and select Windows XP (Service Pack 3) from the drop down.
Under Settings, check the Reduced color mode checkbox, and change the dropdown to 16-bit (65536) color.
Put a check mark in the Disable display scaling on high DPI settings.
Click Ok, then Ok again.
Aaaand …. Done!
Okey dokey. You should be all set.
Now you should be able to run the IDE with no problem. On my screen, a red border appears when moving or sizing a control or form, but may appear differently on your monitor depending on your video driver.
I hope this tutorial proves useful. I know it’s a bit wordy, and for that I apologize. I do try to paint a clear picture, though. If you have any comments or questions, please feel free to contact me through private message (logged in users only), or you can leave a comment below.
Have a great day!