Given that the Visual Basic 6.0 runtime ships with Windows 7 and will continue to be supported for the lifetime of the OS (until January 2020) and that the Visual Basic 6.0 IDE, though no longer supported, is fairly stable, what are the risks around keeping mission-critical applications in Visual Basic 6.0 for the next several years?
The official advice for owners of VB6 apps from Microsoft UK is:
[Do not upgrade or replace your VB6 application if] your application is working great, it has not required any changes for many years, there are no plans to extend the functionality, nor a need to integrate it with newer applications
That tells you the factors that increase risk for a VB6 application:
- A need to change the application (bug fixes or new features).
- A need to integrate the application with newer applications.
- But integration doesn't require migration. Interop allows you to mix .Net code with VB6 (PDF whitepaper).
EDIT I forgot to mention the main risk. Migrating VB6 code to .Net can be a big task. In my opinion it's currently easier than it was in the early days: there are now excellent commercial tools; and some more recent VB.Net language features make it easier. The risk is that it may become harder again if you leave it too long. There will come a point when most people who are ever going to migrate have already migrated: then the tools may disappear and the community knowledge about migration may degrade. /EDIT
I'm sure Microsoft will eventually drop the VB6 runtime, but bear in mind that Windows 8 still supports 16-bit applications. And then there's virtual machines. Personally, I think VB6 applications will be running for a long while yet.
One risk is that you are working in a language which developers mostly don't want to deal with. It will be harder to find good developers as current developers leave or you need to expand the application.
Furthermore, you are increasing the size of the code base which you might some day want to upgrade to another language.
Biggest of all is that adding new features to your VB6 application is more expensive than it would be if the application was in a better language like C# or VB.NET. This is because:
- VB6 developers cost more to employ. Since developers don't want to use VB6 they will demand more money to accept a position at your company (I would)
- .NET has a much larger standard library and more 3rd party components than VB6. In my experience, there are many more open source 3rd party components in .NET while the VB6 components are often proprietary.
- using Visual Studio 2008 or 2010 is more productive than the VB6 IDE because of all the improvements and features from the last 10 years.
- .NET has better unit testing support.
- C# is a better language than VB6. A good C# developer can write a feature much faster than a good VB6 developer because the language is much more powerful.
There are many risks... For example, if a security hole is found with the VB6 runtime - will MS invest the money to fix it? There is a good chance that they will, but at this point it's so old they might not bother.
The risk evaluation also needs to be based on how mission critical your app is, and how big / complicated it is. If this is at the core of your business and a single day's worth of downtime would bankrupt your business, I would be looking at replacing it pretty quickly with something that is actually supported.
The other side of the coin is, you have a lot of company. There is still a lot of VB6 code in production (I'm pretty sure that some of the stuff I wrote in VB6 is still running).
Another possible risk also comes with the use of old ocx that have a 16 bit setup.exe for development environment.
You can't run 16-bit setup on a new 64-bit o.s. development environment.
Quote for example Farpoint Spread 3.0.16: it has a 16 bit developer setup but in this lucky case you can find an upgraded 32bit setup.exe application.
Some ocx do not have 32 bit setup.exe for development environment.
Often there are problems with old ocx serial numbers / registration keys. With some of those ocx you don't get support anymore
Applications in VB6 are made in huge quantities today. Simply put, they are reliable. There are no risks, but just an impediment, is not cross platform. There is enormous many online open source VB6 projects for all domains. It is now used in Linux. It works very well with embedded ASM for low level functions.
Some good points:
VB6 components are free online.
VB6 is more productive than Visual Studio 2008 or 2010 or any other language after VS6.
Contrary to what has been said above, VB6 is a better language than C# (is way faster too). A good VB6 developer can write a feature much faster than a good C# developer because the language is much more powerful.
来源:https://stackoverflow.com/questions/3319561/risks-around-relying-on-visual-basic-6-0-applications