Missing Reference to Comdlg32.ocx

J

Jack Gillis

I have Google Group'ed this problem and found a lot of information that,
frankly, is beyond me because I don't have a lot of experience in VBA.

Here is the problem under Access 2003 and XP SP2.

I have an database file that works just fine on the machine it was
developed on. When I use that database on another machine, I
immediately get a message saying that it has a missing or broken link
reference to the file 'comdlg32.ocx'. I found how to fix this by
unchecking the Microsoft Common Dialog Control 6.0 in VBA's references
and compiling the database again.

What I would like to know is this. Is there a way to determine which
function call or other line in the VBA code is the origin of this
problem so I can re-do the code to get around it? Maybe I have some
un-needed code in a module that can be eliminated.

Micro Soft Office Assistance, in Troubleshoot undefined functions and
references to projects or libraries suggests 'You can't call a class
module from a query, form, report or macro. Store a Visual Basic
procedure in a standard module if you need to call it from a query,
form, report or macro'. I probably have such a call in one of the
prohibited areas and am more than willing to search it out if I could
identify it and knew where to store it. I'm not sure I even know what a
Standard Module is.

As I said, I am in way over my head dealing with VBA at this level and
would really appreciate any help I receive.

Thank you.
 
B

Brian

Jack Gillis said:
I have Google Group'ed this problem and found a lot of information that,
frankly, is beyond me because I don't have a lot of experience in VBA.

Here is the problem under Access 2003 and XP SP2.

I have an database file that works just fine on the machine it was
developed on. When I use that database on another machine, I
immediately get a message saying that it has a missing or broken link
reference to the file 'comdlg32.ocx'. I found how to fix this by
unchecking the Microsoft Common Dialog Control 6.0 in VBA's references
and compiling the database again.

What I would like to know is this. Is there a way to determine which
function call or other line in the VBA code is the origin of this
problem so I can re-do the code to get around it? Maybe I have some
un-needed code in a module that can be eliminated.

Micro Soft Office Assistance, in Troubleshoot undefined functions and
references to projects or libraries suggests 'You can't call a class
module from a query, form, report or macro. Store a Visual Basic
procedure in a standard module if you need to call it from a query,
form, report or macro'. I probably have such a call in one of the
prohibited areas and am more than willing to search it out if I could
identify it and knew where to store it. I'm not sure I even know what a
Standard Module is.

As I said, I am in way over my head dealing with VBA at this level and
would really appreciate any help I receive.

Thank you.

There may not be anything in your database using the common dialog control.
Access will complain about the missing reference even if it is not being
used.

In any case, it's an ActiveX control, so what you are looking for is a
common dialog control on a form. It's not something you can do by
accident! If everything seems to be working OK without the reference, then
I wouldn't worry about it.
 
J

Jack Gillis

Brian said:
There may not be anything in your database using the common dialog
control.
Access will complain about the missing reference even if it is not
being
used.

In any case, it's an ActiveX control, so what you are looking for is a
common dialog control on a form. It's not something you can do by
accident! If everything seems to be working OK without the reference,
then
I wouldn't worry about it.

Thank you very much, Brian.

Well, so far things seem to work OK without the reference but the
message popping up each time I open the file on another computer is
annoying. I guess I will have to search through all the forms for an
ActiveX control That is, if I can find out how to identify one. Any
hints there?

Thanks again.
 
B

Brian

Jack Gillis said:
Thank you very much, Brian.

Well, so far things seem to work OK without the reference but the
message popping up each time I open the file on another computer is
annoying. I guess I will have to search through all the forms for an
ActiveX control That is, if I can find out how to identify one. Any
hints there?

Thanks again.

You need to remove the reference before you distribute the database to other
computers. If you've got copies out in the wild which still have the
reference, then you need to replace them with a copy which doesn't have the
reference. Whether you actually have a Common Dialog control on a form has
nothing to do with it: Access is checking the references for missing ones
when you open the database, it isn't checking to see whether you've actually
used a Common Dialog Control.

To see what a common dialog control looks like, try adding one to a form:
click the "More Controls" button on the toolbar, and scroll down the massive
list until you find "Microsoft Common Dialog".

Please don't get seduced by all the wunnerful new controls in the "More
Controls" list: most serious Access developers avoid these ActiveX controls
like the plague, precisely because of the kind of problem you are
experiencing.
 
J

Jack Gillis

Thanks again, Brian.

That was very worthwhile. I have removed it in all know distributed
files.
 
Joined
Oct 22, 2008
Messages
1
Reaction score
0
Fix Comdlg32.ocx

Hi Guys

I am new to this forum but have an easy solution this post.
Download a new Comdlg32.ocx from http://www.afreeocx.com/ocx/info/comdlg32_ocx.html

Copy it in C:\windows\system32\

Then register it
start an type the following ;
regsvr32 C:\WINDOWS\system32\Comdlg32.ocx in the run command.

Thi should work as I did it for the regsvr32 C:\WINDOWS\system32\asctrls.OCX for this and it works,

Cheers



Brian said:
"Jack Gillis" wrote in message
news:[email protected]...
>
> "Brian" wrote in message
> news:[email protected]...
> > "Jack Gillis" wrote in message
> > news:[email protected]...
> >> I have Google Group'ed this problem and found a lot of information
> >> that,
> >> frankly, is beyond me because I don't have a lot of experience in
> >> VBA.
> >>
> >> Here is the problem under Access 2003 and XP SP2.
> >>
> >> I have an database file that works just fine on the machine it was
> >> developed on. When I use that database on another machine, I
> >> immediately get a message saying that it has a missing or broken link
> >> reference to the file 'comdlg32.ocx'. I found how to fix this by
> >> unchecking the Microsoft Common Dialog Control 6.0 in VBA's
> >> references
> >> and compiling the database again.
> >>
> >> What I would like to know is this. Is there a way to determine which
> >> function call or other line in the VBA code is the origin of this
> >> problem so I can re-do the code to get around it? Maybe I have some
> >> un-needed code in a module that can be eliminated.
> >>
> >> Micro Soft Office Assistance, in Troubleshoot undefined functions and
> >> references to projects or libraries suggests 'You can't call a class
> >> module from a query, form, report or macro. Store a Visual Basic
> >> procedure in a standard module if you need to call it from a query,
> >> form, report or macro'. I probably have such a call in one of the
> >> prohibited areas and am more than willing to search it out if I could
> >> identify it and knew where to store it. I'm not sure I even know
> >> what a
> >> Standard Module is.
> >>
> >> As I said, I am in way over my head dealing with VBA at this level
> >> and
> >> would really appreciate any help I receive.
> >>
> >> Thank you.
> >>
> >>

> >
> > There may not be anything in your database using the common dialog
> > control.
> > Access will complain about the missing reference even if it is not
> > being
> > used.
> >
> > In any case, it's an ActiveX control, so what you are looking for is a
> > common dialog control on a form. It's not something you can do by
> > accident! If everything seems to be working OK without the reference,
> > then
> > I wouldn't worry about it.
> >
> >

>
> Thank you very much, Brian.
>
> Well, so far things seem to work OK without the reference but the
> message popping up each time I open the file on another computer is
> annoying. I guess I will have to search through all the forms for an
> ActiveX control That is, if I can find out how to identify one. Any
> hints there?
>
> Thanks again.
>
>


You need to remove the reference before you distribute the database to other
computers. If you've got copies out in the wild which still have the
reference, then you need to replace them with a copy which doesn't have the
reference. Whether you actually have a Common Dialog control on a form has
nothing to do with it: Access is checking the references for missing ones
when you open the database, it isn't checking to see whether you've actually
used a Common Dialog Control.

To see what a common dialog control looks like, try adding one to a form:
click the "More Controls" button on the toolbar, and scroll down the massive
list until you find "Microsoft Common Dialog".

Please don't get seduced by all the wunnerful new controls in the "More
Controls" list: most serious Access developers avoid these ActiveX controls
like the plague, precisely because of the kind of problem you are
experiencing.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top