none
Using VB6 on Vista RRS feed

  • Question

  • Is VB6 support on Vista as a development language?

    I have a VB6 application (which is pretty big), but when I come to compile it on Vista RC2 is fails to register all the activeX dlls that are build as part of the application.

    I did manage to get round it, but  only by running VB6 as Administrator. In a day to day dev environment I don't want to do this every time. I am a local admin so why doesn't this allow VB to register my dlls.

    Does this behavior have something to do with UAC?

    Thanks for your help

    Graham

    Monday, October 23, 2006 11:48 AM

Answers

  • This is a UAC issue. 

    We’ve been testing the Visual Basic 6.0 SP6 runtime and IDE on Vista builds since earlier this year.  Both run and install successfully on Vista RTM and are supported per the support statement posted at http://msdn2.microsoft.com/en-us/vbrun/ms788708.aspx

     

    The Visual Basic 6.0 IDE and SP6 setup needs to be run with UAC on, with the local user running as Admin, running with elevated privileges (right click on the setup exe and select “Run As Administrator…”). 

     

    Applications based on the Visual Basic 6.0 runtime need to be run under the same security/runtime settings (UAC/Admin/Elevated).  This allows actions like registry reads/writes possible under UAC control.

     

    Please reply back if you application does not work under these settings.

     

    Also, refer to http://msdn2.microsoft.com/en-us/vstudio/aa948853.aspx for information about running Visual Basic 2005 under UAC on Vista.

     

    Thanks,

              Chris Mayo

              Visual Basic Program Manager

     

    Thursday, November 30, 2006 4:09 AM

All replies

  • I know most of you will probably know this already, but...

    On further reading for some Vista docs it appears that UAC means that all interactive users run as a standard user, even if the logged on user is a member of the Administators group.

    This will explain why when I simply double click the VB6.exe (or the vbg file) it won't compile properly as it tried to register the com components it has just built - you have to be an administrator to register com dlls. By right clicking and choosing Run As Administrator elevates my permissions when I run VB6 and with these new permissions I (or VB) can now register the dlls.

    This brings to mind another question for you all...

    What are the recommendations for running VB6 or any other dev tool that needs to perform tasks like the above? Should I be disabling UAC for me as a Windows User? Does VS 2005 suffer from the same symptoms?

    Thanks

    Graham

    Tuesday, October 24, 2006 8:30 AM
  • This is a UAC issue. 

    We’ve been testing the Visual Basic 6.0 SP6 runtime and IDE on Vista builds since earlier this year.  Both run and install successfully on Vista RTM and are supported per the support statement posted at http://msdn2.microsoft.com/en-us/vbrun/ms788708.aspx

     

    The Visual Basic 6.0 IDE and SP6 setup needs to be run with UAC on, with the local user running as Admin, running with elevated privileges (right click on the setup exe and select “Run As Administrator…”). 

     

    Applications based on the Visual Basic 6.0 runtime need to be run under the same security/runtime settings (UAC/Admin/Elevated).  This allows actions like registry reads/writes possible under UAC control.

     

    Please reply back if you application does not work under these settings.

     

    Also, refer to http://msdn2.microsoft.com/en-us/vstudio/aa948853.aspx for information about running Visual Basic 2005 under UAC on Vista.

     

    Thanks,

              Chris Mayo

              Visual Basic Program Manager

     

    Thursday, November 30, 2006 4:09 AM
  • I'm not able to install both Visual Studio Service Pack 5 and VB6 Service Pack 6.

    I have Windows Vista x64.

    Obviously, I have tried compatibility stuff and "Run as Admin".

    How can I solve this issue ?

    Wednesday, January 17, 2007 4:27 PM
  • I'm assuming this is the same for the final release version of Vista and not just the Release Candidates?

    If so, forcing my customers to change their admin settings prior to installation or use of my software is a completely unacceptable solution.

    Users do not understand, or care to understand, the need to change settings so applications they've always used work again. When a customer buys my product, and installs it, they expect it to just work.. and just work exactly like it did under WindowsXP.

    If a user has to make system setting changes so that the product works, that's a horrendous user experience. It also means that they'll be calling me asking for help. That's money out of my pocket for support calls.

    And this isn't a trivial VB6 app I'm selling. It's a project that has taken 3 years of development, sells in the thousands, and it is not at all possible to upgrade it to the VS2005 version (the upgrade process fails miserably) without a major rewrite (mostly because the VB development team at Microsoft completely destroyed the language! Seriously, when are we going to get a VB7 that is actually VB?)

    That means I'm using VB6 for the foreseable future. I expect that my software install and function on Vista in exactly the same fashion that it did on XP(and Win98 for that matter). No changing of admin rights, not special security changes, nothing. It should just work.

    Period.

    Tuesday, January 30, 2007 10:39 PM
  • Portions of one of my applications are created with VB6.

    We've been able to successfully run these VB6 created EXEs under a Vista limited user account with UAC active with no problems. I would think you would only need an Admin account if you actually needed to write to a limited access area of the registry or some limited access file.

    I doubt we will ever go through the agony of trying to run Visual Studio 6 on Vista. We plan to keep that on XP for now.

    You should probably just try your app under a Vista limited account with UAC on and see what issues there are, if any.
    Wednesday, January 31, 2007 1:23 AM
  • So I have a brand new laptop with Vista Home Premium on it. I have Visual Studio 6 CD's from the MSDN kit. Knowing that C++ doesn't install, I go into custom options and uncheck that program (although I firmly believe it should be supported).

    Go through the whole process of installation. It ~looks~ to work.. except when I start it. I'm immediately presented with a dialog that says one of the core OCX files is not registered or missing. Then a progression of other warnings and errors about Object Blocks not being set.

    I skip all that. Load up my program group and am presented with a bunch of NEW problems.. the tabdlg.ocx is missing, along with a collection of other controls that is preventing my COM dll from loading. Thus, preventing me from even running a test compile.

    Is there a step by step set of instructions for installing Visual Studio 6 (sans C++) properly located anywhere on the Microsoft site? The MS folks claim they support it, yet I can't find any information on how to actually install it and make it work.

    Wednesday, January 31, 2007 8:07 AM
  • Hi

    I presume this is VB6 we are talking about then. You must remember to lauch VB6 IDE as an Administrator. Simply find the shortcut for Visual Basic 6.0, right click on it then in the Compatibility tab select the option that say: Run this program as an Administrator.

    Hope this helps.

    Friday, February 2, 2007 7:45 AM
  • Hi.

     

     Yes, I've tried that. However when I run the IDE with that checkmark checked, none of the OCX's are found to be registered. The only way I can actually get the IDE to start normally, is if it's not as an admin.

    So with admin on, the IDE starts normally, although I can't register any OCX/DLL files when I compile.

    With admin off, the IDE doesn't start properly at all, causing a lot of problems for the loading of projects.

    Friday, February 2, 2007 10:07 PM
  • I dont know ?????????/

    Sunday, January 27, 2008 8:06 PM
  • I know this is an old thread, but have you tried installing the IDE as Administrator?  Obviously the DLLs are not getting registered on install.

    Finally, to get upset because a 14 year-old piece of software doesn't work on Vista
    without extra steps is more than a little silly.
    Monday, August 18, 2008 5:19 PM
  • I don't think it is 14 years old, but for sure it is still widely used and there is a lot of software around written in VB6.

     

    Microsoft is aware of this and is encouraging writing mixed applications using VB6 and .NET stuff. Porting some VB6 applications to .NET can be a nightmare, especially when u have some 100.000 lines of code to convert.

     

     

    Monday, August 25, 2008 2:18 PM
  • I don't know where I got 14 years from...it's actually a little over 10.  But my point stands; why expect (very) old software to run on a new OS?

     

    My company has 95% of its code in VB6 and it will be a major pain to port all of it to .NET, but we don't expect it to work on Vista without some major tweaking.  It's one of the reasons that we're not even looking at Vista yet.

     

    Monday, August 25, 2008 2:53 PM
  •  

    "My company has 95% of its code in VB6 and it will be a major pain to port all of it to .NET, but we don't expect it to work on Vista without some major tweaking.  It's one of the reasons that we're not even looking at Vista yet."

     

    That sounds like you're writing software for purely internal use and you can control what OS the software is run on. If so, that is a luxury not everyone has. My company sells software (games among other things) to the general public so I really have no idea what OS they're going to be running. But I do know they get really PO'd if they go out and buy a new computer and they can't run the software they already own. Especially if the reason for the purchase of a new computer is to use that software.

     

    So yes, VB and all its parts must work on Vista.

    Monday, August 25, 2008 3:10 PM
  •  Spivonious wrote:

    I don't know where I got 14 years from...it's actually a little over 10.  But my point stands; why expect (very) old software to run on a new OS?

     

    My company has 95% of its code in VB6 and it will be a major pain to port all of it to .NET, but we don't expect it to work on Vista without some major tweaking.  It's one of the reasons that we're not even looking at Vista yet.

     

    Ah, OK, I didn't understand, now it is more clear.

     

    One major rule about development tools and operating systems should be that what you did in the past should work in the future. Otherwise:

    1) Companies (like yours) will continue to use old stuff

    2) Customers will not understand why they have to spend a lot of money buying a porting instead of buying new functionalities

    3) When there will be no more support for old PCs and PCs will be too new to install old OSs, you will have to change hardware, change OS and change development tools all at once
    Monday, August 25, 2008 4:05 PM
  • Yes, all of our software is internal, which definitely saves time on testing. Smile

     

    "So yes, VB and all its parts must work on Vista."

    I think maybe we're misunderstanding each other.  VB6 applications work with no problems on Vista, except where they might need adminstrative access (according to MS, I haven't tested this myself).  It's the IDE that people are having trouble installing.  Since VB6 is no longer supported, I don't expect the IDE to "just work" on Vista, an OS that wasn't even in people's imaginations when the VB6 IDE was released.

     

     

    "One major rule about development tools and operating systems should be that what you did in the past should work in the future. "

     

    So your opinion is that I should be able to take code I wrote for DOS and have it work without any problems on Windows 7?  I should be able to run Borland C++ 4 on Vista?  If everything was backwards-compatible we would never move forward.

    Monday, August 25, 2008 4:46 PM