Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Class not registered 4

Status
Not open for further replies.

jimstarr

Programmer
Feb 6, 2001
975
US
An existing app of mine (VFP9) uses FoxPro's _olecalendar control. It's been working fine, except now under Windows 7 the user gets a "Class not registered" error. What to do?

Thanks!


Jim
 
Run your setup as administrator.

Borislav Borissov
VFP9 SP2, SQL Server 2000/2005.
 
I didn't mention that this application will be shipped to my client's customers all over the world, and needs to be easily installed by any user. -Jim
 
Jim,

Does your existing distribution install and register COMCTL32.OCX?

If it does, then this is worrying, because it points to some lack of compatibility in Windows 7.

If it doesn't already install and register that file, trying adding it to your distribution.

Either way, let us know the upshot, as it's the sort of thing that could affect a lot of us as Windows 7 becomes more widespread.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro tips, advice, training, consultancy
Custom software for your business
 
Hi Mike,

It installs MSCOMCT2.OCX but not COMCTL32.OCX. I'll add COMCTL32.OCX to the install and let you know what happens.

Jim
 
You need to add comctl32.dll. These are very old ActiveX controls, and while they still work, they are not included in even Windows XP unless you have some application installed that installs these controls and that was typically the case with Office, until there is Office 2007, which does not seem to use these controls.

DEtails of what I just said might be wrong, but in general you'd need to provide the installation of activex controls anyway to make sure they run on any system. You're just having luck, that usage of these controls is so common, that you didn't ran into problems earlier.

Bye, Olaf.
 
I added COMCTL32.OCX and COMCTL32.DLL to the install (INNO Setup) but the error persists.

Jim
 
The user is trying to register the OCX and DLL by hand, and is getting error messages like:

"The module 'COMCTL32.DLL' was loaded but the entry-point DllRegisterServer was not found. Make sure that COMCTL32.DLL is a valid DLL or OCX file and then try again"

He has tried this with multiple copies of the files.

Jim
 
The user has discovered that if he runs the app as administrator, it works.

Jim
 
As I said, run the setup as administrator/
There is no other way to register ActiveX under Vista and Win7.

Borislav Borissov
VFP9 SP2, SQL Server 2000/2005.
 
I'm not sure what you mean by "run the setup." -Jim
 
You have ate least one executable file (with EXE extension) after you created your installable package.
Usually it is named SETUP.EXE (or INSTALL.EXE).
No matter how it is called you (or your user) should run it AS ADMINISTRATOR.
Just right click on it and choose "Run as Administrator" from the right click menu.


Borislav Borissov
VFP9 SP2, SQL Server 2000/2005.
 
I'm told that running the setup as administrator doesn't solve the problem. However, running the app itself as administrator solves it once and for all on that computer. The problem can't even be recreated by uninstalling and reinstalling the app.

Jim
 
Jim,

Thanks for that update. The behaviour you described seems a bit odd, but at least it solves the problem.

I wonder what other surprises Windows 7 has in store for us VFP folk.

Mike



__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro tips, advice, training, consultancy
Custom software for your business
 
Mike,

The user doesn't consider the problem solved. It's OK that the install must be run as administrator, but not the app itself.

Jim
 
Jim,

I misunderstood. I thought you said you only have to run it once as administrator ("running the app itself as administrator solves it once and for all on that computer").

So you always have to run it as administrator? If so, I can see why that wouldn't solve the problem.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro tips, advice, training, consultancy
Custom software for your business
 
Only once is enough, but the requirement is that only the install be run as administrator.

Jim
 
Sounds like you need to create a post-setup executable that takes care of whatever it is that has to be done as admin.

Tamar
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top