Solved

Crystl32.ocx not registering

Posted on 2001-08-17
13
1,526 Views
Last Modified: 2012-08-14
Hi Guys,

After removing an old VB application (that used the crystl32.ocx), I installed a new VB application that uses the latest Crystl32.ocx (from version 8.5), my problem it that the new OCX doesn't seem to want to register. The error message I'm getting is as fillows (This is taken from the uninstall file) :

*** ERROR: LoadLibrary() failed while registering file 'C:\WINDOWS\SYSTEM\Crystl32.OCX'
*** DURING THIS ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\Crystl32.OCX"

I also tried registering the file using REGSVR32 - still no joy.


Any clues??


GarrenB
0
Comment
Question by:garrenb
  • 6
  • 4
  • 3
13 Comments
 
LVL 11

Expert Comment

by:Otana
ID: 6396957
have you tried unregistering the old version first?
0
 
LVL 1

Author Comment

by:garrenb
ID: 6396999
I removed the old application using Add/Remove programs which removed the old ocx for me.
0
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6397064
Look for the Crystl32.dep file on your system.  It will show you what other files the Crystl32.ocx requires.  Then make sure they are on your machine, and the version are correct.  Then it should work.
0
 
LVL 11

Expert Comment

by:Otana
ID: 6397066
Well, try to unregister the ocx anyway, using regsvr32, but with the option /u

Afterwards, try to register your new ocx again. I'm not sure it will work, but it won't hurt to try.
0
 
LVL 1

Author Comment

by:garrenb
ID: 6397211
To Dave :
I checked the .dep file and the pdw *does* include the files (3 in total) but the error still occurs. When manually trying to register the file the Error Message reads "Load Library (c:\windows\system\crystl32.ocx) failed. GetLastError returns 0x00000485"

Does this help.

To Otana :
The Add/Remove in Windows *Removes* the Crystl32.ocx from the system. Hence there is nothing to unregister.


GarrenB
0
 
LVL 11

Expert Comment

by:Otana
ID: 6397227
The file will be removed from the system, but it's possible there's still a reference to it in the registry.
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 1

Author Comment

by:garrenb
ID: 6397315
To Otana,
I did also removed any refrence to the ocx inside the registry.

This is driving me mad.

GarrenB
0
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6397510
"I checked the .dep file and the pdw *does* include the files (3 in total) "

Are you sure that the versions of the dependancy files are correct?  I'll bet my bottom dollar that they are not...
0
 
LVL 1

Author Comment

by:garrenb
ID: 6397681
Hi Dave,

I manually added the files from my own system32 folder in Windows 2000 into the PDW so they really have to be correct (Don't they??)

GarrenB
0
 
LVL 8

Expert Comment

by:Dave_Greene
ID: 6397726
There could be duplicates!!!  I would check the registry and search for the individual components and see which ones are currently registered.  Those are the ones you want!  Assuming that it works on the dev machine of course.
0
 
LVL 1

Author Comment

by:garrenb
ID: 6398732
Hi Dave,
Yeah naturally I have no problem running it on the dev machines and it also runs on a pc with a new clean installation (this is why I think that the files are up to date) the only problem is trying to register the file on a machine that had the older version installed at some point in it's life.

GarrenB
0
 
LVL 8

Accepted Solution

by:
Dave_Greene earned 50 total points
ID: 6398772
It's probably a stupid versioning problem.  I bet the developers at crystal screwed up versioning a few years ago, and it's still haunting the application.

What may have happened (I did it when I was a newbie, eons ago) One of the supporting files that the OCX relies on could have versioning issues.  Say you built a DLL, then made modifications to it through out the years with Auto-Increment turned on.  By the time you ship it has been set to version 2.1.113  Then you build your package and deploy it.  No problem.  Now say, it's a year later and your boss wants you to ship version 2.  Well you think, ok, to clean up these old files I'll deploy the new version of the controls as 2.0.0.  No problem right?  You didn't break compatibility and the versions are now set so even a developer knows what version he/she is working on.

Then the problem becomes realized.  Microsoft in all of it's wisdom (not a cut-down), silently performs version checking for everyone... not just the MS stuff.  So when you attempt to register the new DLL, everything appears fine, no error messages, no versioning problem messages.... but you app won't run.

There is no easy way to clear this up either.  You have to hunt down and kill every entry related to the problem components in the registry, then Re-Deploy...  It's ugly.  But if you do it to that old test machine, I'll bet you get it running.

Hope this helps your situation!

Dave
0
 
LVL 1

Author Comment

by:garrenb
ID: 6436206
Hi Dave,

My problem was that the PDW didn't include all the runtime files reqd. All previous versions of VBs PDW did this. Anyway, in the help file runtime.hlp in crystal reports it gave me a list of all the reqd files so I'm up & running.

All the best

GarrenB
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Vb.net 2008 2 49
VBA color chart bars 12 66
Restricting text box entry from \/:?<>"| 9 62
vb6 connector to SQL Server 2 32
I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now