PDA

View Full Version : VB6 Components Not Properly Registering In Vista



PerryArcher
03-04-2007, 05:54 PM
Microsoft's support statement says that Vista Supports the following VB6 Controls...

http://msdn2.microsoft.com/en-us/vbasic/ms788708.aspx

* tabctl32.ocx

* msbind.dll

* richtx32.ocx

Yet each of these controls has failed to register properly on various customer's Vista Machines despite all efforts on my part to ensure that the components are registered properly when they are installed. Not always the same control for different machines.

I don't know where to turn. I have been cruising Online Forums and Googling for weeks to resolve these problems. Microsoft states that it supports these Microsoft Controls in Vista . My installs are working for every other 32-Bit Version of Windows. I have upgraded my installer to the InstallShield Express 12 and yet am no closer to solving the problem.

I have also observed the following issue on my Windows Vista Home Premier Test Bed Machine.

I installed my application using an Admin Account. When I first ran the application, I received the error message shown in the attached picture.

I ran the application again with no error messages being generated. I as able to exercise all functions of the application without error.

I then created a second user account on the Machine with Standard User Priviledges. When I ran the application from this account, I received the same error message as above.

I then elevated the Second User Account to Admin and attempted to register the component. The computer was unable to register this control, despite successfully registering the control and running the application on the original installation User Account. I was never able to resolve this issue for the Second User Account.

After returning to the original User Account, the program continued to work properly.

I then performed a clean install of Windows Vista and verified that the problems described above were repeatable.

Any help or insight you can provide would be greatly appreciated.

Thanks,

Perry

Christopher Painter
03-04-2007, 07:19 PM
When you run regsv32, are you tasking UAC for an elevated token? Try running a Command Prompt with your admin token and see what happens.

If that still doesn't work, run depends and other profiling tools like Regmon and Filemon to investiage what dependencies are missing

I just tried regsvr32 on richtx32.ocx without my admin priv and it failed. Elevating the process caused it to work.

PerryArcher
03-05-2007, 02:03 AM
Christopher,

Pardon my ignorance, but how do I task UAC for an elevated token? I simply tried elevating the second user to Admin Account and ran regsv32.

If you know of a good source for Vista Specific Install Requirements, I would appreciate the link.

Thanks for your time.

Perry

Zookeeper64
03-19-2007, 02:58 PM
I'm having the same problem with ISE X.

Do you have the Microsoft Tabbed Dialog Control 6.0 merge module included in your project? If so go to "Redistributables" in the left pane (that's how it works with ISE X - I don't know if it is different in ISE 12) and see if you have the Microsoft Tabbed Dialog Control 6.0 merge module selected. If you do then see if you have "ScannedProject" checked only or if "Always Install" is also checked. In my project I only have "ScannedProject" checked. I suspect that checking "Always Install" will fix the problem but I can't determine it from the documentation. Also, my Vista test machine (Vista Home Premium) isn't experiencing any problems with my current setup. Only a few of my Vista users are having the problem.

Rasnil
03-19-2007, 03:19 PM
Guys I have been working on some of the same issues with Vista myself. I found that what I believe Christopher ment by tasking uac to run an elevated token simply ment run cmd.exe with administrative rights. To do this simply explore to c:\windows\system32 and right click cmd.exe and left click run as administrator. This has allowed me to register ocx components without error with regsrv32.

As far as how to handle registering components during an MSI install, I found this link you may find helpful.

http://blogs.msdn.com/cjacks/archive/2006/10/30/deferred-custom-actions-and-permissions-on-windows-vista-with-uac-enabled.aspx

Zookeeper64
03-19-2007, 03:29 PM
Guys I have been working on some of the same issues with Vista myself. I found that what I believe Christopher ment by tasking uac to run an elevated token simply ment run cmd.exe with administrative rights. To do this simply explore to c:\windows\system32 and right click cmd.exe and left click run as administrator. This has allowed me to register ocx components without error with regsrv32.

As far as how to handle registering components during an MSI install, I found this link you may find helpful.

http://blogs.msdn.com/cjacks/archive/2006/10/30/deferred-custom-actions-and-permissions-on-windows-vista-with-uac-enabled.aspx
I'm afraid I don't know what he is referring to when he speaks of custom actions. All I know is that when my Setup is started on Vista with UAC turned on the user is prompted to allow the setup to run as administrator. If they deny permission then the setup doesn't run. If they grant permission then it runs with admin privs. What am I missing?

PerryArcher
04-13-2007, 11:33 AM
Thanks for the follow up guys. I still have been unable to resolve my problems with TabCtl32.ocx. I do have the Microsoft Tabbed Dialog Control 6.0 merge module included in my project.

The software installs and works fine for a user that has Admin Priviledges.

However, when logging into the same computer by a second user with Standard Privileges the second user receives the same error posted in my earlier message.

I cannot find a way to register this component (and several other Microsoft Components) for All Users in Vista. I do not have this problem with any other 32-Bit Microsoft Operating System.

Good Luck and look forward to hearing from anyone that has had success installing V6 Applications that work for All Users in Vista.

BTW: I have set privileges for the Application & Data Directories for All User Read/Write access in the InstallShield Project and verified that the privileges are set properly for all users following installation.

Thanks,

Perry

mindserve
04-13-2007, 12:21 PM
Ok, what Microsoft means is that they "support" those dll's and OCX files, but they are NOT "shipped" with Vista. So what does that mean? We support you, we just won't include them with VISTA...hummmmm.... Which means you must add them to your applications and distribute them with your apps. I found most of the following files were missing in my vb6 applications and some existing ones just needed to be un- registered and re-registered in a bat file. I have created this below for you. Just paste to a text file and rename it with the bat extension. This will run silently on the users PC. Adjust the dll's and ocx files as needed for your apps. your program will let you know what is missing when it's run after the reboot on Vista. On XP upgrading to Vista it runs ok, but on clean installs I had to have the users turn OFF the UAC before installing the program then run this bat file. I am not happy with the UAC, and it seems really cumbersome for users. Wondering why these files are supported if they do not register properly on Vista. This is a bug in VISTA Imo...something they need to address for developers. BTW, I know the PDW does not work for VISTA and I have only been using Microsoft's own free Visual studio installer 1.1 , no third party product. So if it doesn't work on Microsoft's OWN installer, then how can it work for a third party installer.

regsvr32 /u /s msflxgrd.ocx
regsvr32 /u /s comdlg32.ocx
regsvr32 /u /s msbind.dll
regsvr32 /u /s mswinsck.ocx
regsvr32 /u /s msderun.dll
regsvr32 /u /s msinet.ocx
regsvr32 /u /s mswinsck.ocx
regsvr32 /u /s mscomctl.ocx
regsvr32 /u /s msdatlst.ocx
regsvr32 /u /s msflxgrd.ocx
regsvr32 /u /s msmask32.ocx
regsvr32 /u /s tabctl32.ocx
regsvr32 /u /s mscomm32.ocx
regsvr32 /u /s msdbrptr.dll
regsvr32 /u /s msdatgrd.ocx
regsvr32 /u /s mscomct2.ocx
regsvr32 /u /s mshflxgd.ocx
regsvr32 /u /s msadodc.ocx
RegSvr32 /u /s msvbvm60.dll
RegSvr32 /u /s olepro32.dll
RegSvr32 /u /s comcat.dll
regSvr32 /u /s msstdfmt.dll
regsvr32 /s msflxgrd.ocx
regsvr32 /s comdlg32.ocx
regsvr32 /s msbind.dll
regsvr32 /s mswinsck.ocx
regsvr32 /s msderun.dll
regsvr32 /s msinet.ocx
regsvr32 /s mswinsck.ocx
regsvr32 /s mscomctl.ocx
regsvr32 /s msdatlst.ocx
regsvr32 /s msflxgrd.ocx
regsvr32 /s msmask32.ocx
regsvr32 /s tabctl32.ocx
regsvr32 /s mscomm32.ocx
regsvr32 /s msdbrptr.dll
regsvr32 /s msdatgrd.ocx
regsvr32 /s mscomct2.ocx
regsvr32 /s mshflxgd.ocx
regsvr32 /s msadodc.ocx
regSvr32 /s msvbvm60.dll
regSvr32 /s olepro32.dll
regSvr32 /s comcat.dll
regSvr32 /s msstdfmt.dll

steveyb
10-09-2007, 06:16 AM
Hi,
reference MINDSERVE POST... HOW TO CORRECT DLL/OCX ERRORS IN VISTA...
I"m far from a computer expert but I seem to have the problem that you state ( I think!).
I am currently trying to install FSCopilot and FSInn which are modules to allow one to play
online (multiplayer with voice, ATC,etc) connecting Microsoft FSX flight sim game to
VATSIM (Virtual AirTraffic Simulation)I"ll try not to bore you to much,
I recently purchased Vista 32bit which was the only option available at the time and had to
send off for the 64 bit software, direct from Microsoft,I installed it no problem, and then installed
all my Flightsim software plus FSCopilot and FSinn.Here"s the problem, when I attempt to run
the FsCopilot software, "BING", noise audible and error message "COMPONENT COMDLG32.OCX OR
ONE OF ITS DEPENDENCIES NOT CORRECTLY REGISTERED OR A FILE MISSING OR INVALID",comes up.
Have spent hours on the FSCopilot forum, advice being:= run modules/software as
administrator/turn off UAC,allow appropriate software through my Firewall, etc.
Also run regsvr32 to re-register COMDLG32, could not initially register it until I turned off UAC,
kept coming up with DLLREGISTER SERVER FAILED ERROR CODE 0X8002801C.
Still the fault occurs, tried deleteing the original COMDLG32.ocx but "access is denied", to try and install new updated one.
FSCopilot instruct me to obtain a 64 bit version COMDLG32.dll and manually register it..... is there one?
I have come across loads of the same errors with this situation right across the internet with these modules, but FSCopilot
are adement it is not their problem, its Microsofts and state that many other users with this issue have resolved it with
their measures.
Can you instruct me exactly on how I go about resolving this issue, as I previously said its all "gobbledygook" to me, being
a mere flight simmer.What"s a bat extension... are your listed files just letters (post 382365) or are they active content?


Hope you can help
many thanks Steve

Zookeeper
10-09-2007, 10:41 AM
I finally found out what was causing the problem I was having with some components not being properly registered for some Vista users. It seems there is a bug in the Microsoft Installer Engine in Vista. Here is what triggers the problem:

If the user has UAC turned off and they select the install option to install the application for only by the user account that is running the install then some components just won't register properly. If the same user either turns UAC back on or selects the option during install to install the application for anyone who uses the computer then everything registers correctly and there are no problems.

What I did was use ORCA to edit my MSI so that the option on the setup screen that normally reads "Only for me (user account name)" to "Only for me (user account name) - Don't select this option if using Vista with UAC turned off".

Hopefully Microsoft will get this fixed in Vista SP1.

Azmath
10-10-2007, 03:56 PM
Guys pls help.

I had VS2005 installed in XP and i was working on a project that used COM components. To use them i had to manually register them using regsvr32. Everything was working fine. But now, recently I have installed VS2005 in Vista and am still trying to work on that project to finish it. Now, VS2005 in Vista said that it couldn't recognize some of the COM components as they were not registered. So i decided to register them. I download Richtx32.ocx - one of the controls i was using - and copied it to system32 folder. Then i used command prompt to register the ocx file:

regsvr32 richtx32.ocx

this procedure is what i applied in XP and it worked but in Vista i get an error message saying:

"The module 'richtx32.ocx' may not be compatible with the version of windows that you're running. Check if the module is compatible with an x86 (32-bit) or x64 (64-bit) version of regsvr32.exe."

Thats exactly what it says. nothing more.

P.S.: I have VS2005 Pro and have installed VS2005 SP1, SP1 update for Vista, have activated my copy of Windows and use a 32-bit workstation machine. And i have also tried right-clicking on cmd.exe and running it as administrator method.

Azmath
10-10-2007, 04:12 PM
I found the solution to my problem: the copy of richtx32.ocx i downloaded was corrupt. I downloaded a new copy and registered it. Everything works fine now.

Tony.T
04-03-2008, 04:04 AM
I had the same situation: a vb-program ran fine as admin, but as Standard User it said that tabclt32.ocx was missing or inavlid.

Solution:
- login as administrator
- right-click the ocx-file (search in systemfolders to find it)
- advanced security rights:
-- ADD the Standard User (he wasn't listed)
-- Give the standard user Full Control over the OCX-file; check all the boxes

Maybe you can leave some checkboxes unchecked, I did not care for that.

For me it solved the problem. Hope it does for you too!

T