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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Registering COMCTL32.OCX 1

Status
Not open for further replies.

dja1

Programmer
Apr 24, 2002
65
GB
I have inherited the maintenance of a VB6 application. When I try to load the .vbp using VB6, the "Loading" message appears, then VB6 ends, with no message.

I think I have narrowed it down to when it tries to load a Form that begins Object = "{6B7E6392-850A-101B-AFC0-4210102A8DA7}#1.3#0"; "COMCTL32.OCX"

I have searched my PC, and found COMCTL32.OCX in C:\WINNT\System32.

Is this where it should be? Do I have to "register" it on my machine? If I do, how do I do this?

As usual, any help would be appreciated.
 
The comctl32.ocx is... "Microsoft Windows Common Controls 5.0"

It should be in C:\WINNT\System32

You can register the OCX by doing this...

Click Start->Run
type:
regsvr32 C:\WINNT\System32\comctl32.ocx

If there had been spaces in the path, then you would need quotes around the path and file, like this...

regsvr32 C":\Path With Spaces\Sub Folder\control.ocx"



-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
gmmastros

Thanks for the reply. I used your instructions to register comctl32.ocx, which seemed to work.

Is there any way one can check if it's worked? (I'm not sure if I have sufficient rights to do this, and I am a bit unwilling to ask our "Helpdesk").

If it has registered correctly, it hasn't solved the original problem, (VB6 loading in a project, then disappearing)

Any more help would be appreciated
 
To test that it worked...

start a new VB project
click Project -> Components
scroll down to "Microsoft Windows Common Controls 5.0"
select it.

You'll notice that a few more controls have been added to the toolbox.

One of the controls is a progress bar. Put a progress bar on the form. Then run the app. Of course, you haven't really added any code for the progress, so it won't do anything. However, if you can add a progress bar to your form and run it, then the comctl32.ocx is functioning properly.

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
What does the rest of the .vbp file look like. There may be something else in there that is making it stomp on something to close down VB6. I take it the whole IDE shuts down. Somehow I don't think that comctl32.ocx would cause that. However, if it is possible I hope George can explain.


HyperEngineer
If it ain't broke, it probably needs improvement.
 
gmmastros

Tried your suggestion. I selected "Microsoft Windows Common Controls 5.0", and when I clicked on "OK", VB6 terminated with no message.

I don't know if this indicates that COMCTL32 has not been registered, or if my version of VB6 is stuffed, but I'm afraid it's time to contact out "Help" desk.

Thanks very much for your help


 
gmmastros

It's SP5. I rather think that my inability to add "Microsoft Windows Common Controls 5.0" points more to rights/permissions problems than VB6 problems.

I have contacted our "Help" desk. (No doubt I'll still be asking the same question this time next year).
 
gmmastros and HyperEngineer

Thanks very much for your help. It turned out to be a permissions thing. When I was given developer rights, it worked.

Thanks again
 
May I humbly suggest that you document (in this thread), the permission that caused the problem. It may be helpful for others expereincing the same problem.

-George

Strong and bitter words indicate a weak cause. - Fortune cookie wisdom
 
As suggested by gmmastros, above - the permission given me was "PC Developer", as opposed to "PC User".

(This was the first time I had to use VB6)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top