469,602 Members | 1,984 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,602 developers. It's quick & easy.

Problem with cdo.dll/cdosys.dll

I am using VBA/Access to send SMTP mail using CDO. I set a reference to
"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works
fine, both on my PC and on another PC. However, on another PC that the
database was installed on, the user is getting the message, "The project
contains a missing or broken reference to the file 'CDO.DLL' version 1.21."
However, I don't have a reference to cdo.dll; my reference is to cdosys.dll.
The user has cdosys.dll, but doesn't have cdo.dll.

Any ideas as to what's going on?

Thanks!

Neil
Nov 13 '05 #1
14 12886
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:N1****************@newsread1.news.pas.earthli nk.net...
I am using VBA/Access to send SMTP mail using CDO. I set a reference to
"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works
fine, both on my PC and on another PC. However, on another PC that the
database was installed on, the user is getting the message, "The project
contains a missing or broken reference to the file 'CDO.DLL' version 1.21."
However, I don't have a reference to cdo.dll; my reference is to
cdosys.dll. The user has cdosys.dll, but doesn't have cdo.dll.

Any ideas as to what's going on?
Try
regsvr32 cdosys.dll
b.t.w. is the cdosys.dll exactly the same on both machines?
Thanks!

Neil


Nov 13 '05 #2
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000 Library"
(cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On his
PC (in which there is no error and the code works fine), under references it
says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References, it
had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference to
cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being swapped
out, and where the broken reference to cdo.dll came from?

Thanks!

Neil
"Egbert Nierop (MVP for IIS)" <eg***********@nospam.invalid> wrote in
message news:%2****************@TK2MSFTNGP11.phx.gbl...
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:N1****************@newsread1.news.pas.earthli nk.net...
I am using VBA/Access to send SMTP mail using CDO. I set a reference to
"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works
fine, both on my PC and on another PC. However, on another PC that the
database was installed on, the user is getting the message, "The project
contains a missing or broken reference to the file 'CDO.DLL' version
1.21." However, I don't have a reference to cdo.dll; my reference is to
cdosys.dll. The user has cdosys.dll, but doesn't have cdo.dll.

Any ideas as to what's going on?


Try
regsvr32 cdosys.dll
b.t.w. is the cdosys.dll exactly the same on both machines?
Thanks!

Neil

Nov 13 '05 #3
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000 Library" (cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On his PC (in which there is no error and the code works fine), under references it says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though he didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References, it had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference to cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being swapped out, and where the broken reference to cdo.dll came from?


You would be better off switching to late binding which doesn't require
that you set a reference at all. This offers the following benefits.

In most cases the code becomes version independent. If you ask Windows to
create an object (for example) of "CDO.Message" then any registered library
capable of creating that object can be used.

In cases where no appropriate library exists in an application with a hard
reference you not only get an error when attempting to use that library,
but the reference marked "MISSING" will cause many built in Access
functions to fail. So for lack of an Email library, the whole app might be
rendered useless. With late binding, a PC that lacks an appropriate
library ONLY loses the abilities that the missing library provides. The
rest of the app still works just fine.
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Nov 13 '05 #4
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000 Library" (cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On his PC (in which there is no error and the code works fine), under references it says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though he didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References, it had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference to cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being swapped out, and where the broken reference to cdo.dll came from?


You would be better off switching to late binding which doesn't require
that you set a reference at all. This offers the following benefits.

In most cases the code becomes version independent. If you ask Windows to
create an object (for example) of "CDO.Message" then any registered library
capable of creating that object can be used.

In cases where no appropriate library exists in an application with a hard
reference you not only get an error when attempting to use that library,
but the reference marked "MISSING" will cause many built in Access
functions to fail. So for lack of an Email library, the whole app might be
rendered useless. With late binding, a PC that lacks an appropriate
library ONLY loses the abilities that the missing library provides. The
rest of the app still works just fine.
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Nov 13 '05 #5
One good thing about setting references is that it allows you specify an
order -- as with ADO and DAO -- with the first one being the default.

Anyway, so you're saying that if I omit the reference to CDO and just keep
the rest of the code the same, that it will automatically use the library,
as long as it's registered?

Neil
"Rick Brandt" <ri*********@hotmail.com> wrote in message
news:31*************@individual.net...
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000

Library"
(cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On

his
PC (in which there is no error and the code works fine), under references

it
says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though

he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References,

it
had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference

to
cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being

swapped
out, and where the broken reference to cdo.dll came from?


You would be better off switching to late binding which doesn't require
that you set a reference at all. This offers the following benefits.

In most cases the code becomes version independent. If you ask Windows to
create an object (for example) of "CDO.Message" then any registered
library
capable of creating that object can be used.

In cases where no appropriate library exists in an application with a hard
reference you not only get an error when attempting to use that library,
but the reference marked "MISSING" will cause many built in Access
functions to fail. So for lack of an Email library, the whole app might
be
rendered useless. With late binding, a PC that lacks an appropriate
library ONLY loses the abilities that the missing library provides. The
rest of the app still works just fine.
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com

Nov 13 '05 #6

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:tC*****************@newsread3.news.pas.earthl ink.net...
One good thing about setting references is that it allows you specify an
order -- as with ADO and DAO -- with the first one being the default.

Anyway, so you're saying that if I omit the reference to CDO and just keep the
rest of the code the same, that it will automatically use the library, as long
as it's registered?


No, you do have to make some minor modifications to the code. Instead of...

Dim CDOMsg as CDO.Message
Set CDOMsg = New CDO.Message

....you use...

Dim CDOMsg as Object
Set CDOMsg = CreateObject("CDO.Message")

You also can't use named constants that are defined in the external library, but
instead have to substitute the literal value.

I usually add the reference to create the procedure so I can use the code
completion features of Access and after debugging, make the switch to late
binding.

--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com


Nov 13 '05 #7
One good thing about setting references is that it allows you specify an
order -- as with ADO and DAO -- with the first one being the default.

Anyway, so you're saying that if I omit the reference to CDO and just keep
the rest of the code the same, that it will automatically use the library,
as long as it's registered?

Neil
"Rick Brandt" <ri*********@hotmail.com> wrote in message
news:31*************@individual.net...
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000

Library"
(cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On

his
PC (in which there is no error and the code works fine), under references

it
says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though

he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References,

it
had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference

to
cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being

swapped
out, and where the broken reference to cdo.dll came from?


You would be better off switching to late binding which doesn't require
that you set a reference at all. This offers the following benefits.

In most cases the code becomes version independent. If you ask Windows to
create an object (for example) of "CDO.Message" then any registered
library
capable of creating that object can be used.

In cases where no appropriate library exists in an application with a hard
reference you not only get an error when attempting to use that library,
but the reference marked "MISSING" will cause many built in Access
functions to fail. So for lack of an Email library, the whole app might
be
rendered useless. With late binding, a PC that lacks an appropriate
library ONLY loses the abilities that the missing library provides. The
rest of the app still works just fine.
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com

Nov 13 '05 #8

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:tC*****************@newsread3.news.pas.earthl ink.net...
One good thing about setting references is that it allows you specify an
order -- as with ADO and DAO -- with the first one being the default.

Anyway, so you're saying that if I omit the reference to CDO and just keep the
rest of the code the same, that it will automatically use the library, as long
as it's registered?


No, you do have to make some minor modifications to the code. Instead of...

Dim CDOMsg as CDO.Message
Set CDOMsg = New CDO.Message

....you use...

Dim CDOMsg as Object
Set CDOMsg = CreateObject("CDO.Message")

You also can't use named constants that are defined in the external library, but
instead have to substitute the literal value.

I usually add the reference to create the procedure so I can use the code
completion features of Access and after debugging, make the switch to late
binding.

--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com


Nov 13 '05 #9
"Rick Brandt" <ri*********@hotmail.com> wrote in message
news:31*************@individual.net...

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:tC*****************@newsread3.news.pas.earthl ink.net...
One good thing about setting references is that it allows you specify an
order -- as with ADO and DAO -- with the first one being the default.

Anyway, so you're saying that if I omit the reference to CDO and just
keep the rest of the code the same, that it will automatically use the
library, as long as it's registered?
No, you do have to make some minor modifications to the code. Instead
of...

Dim CDOMsg as CDO.Message
Set CDOMsg = New CDO.Message

...you use...

Dim CDOMsg as Object
Set CDOMsg = CreateObject("CDO.Message")

You also can't use named constants that are defined in the external
library, but instead have to substitute the literal value.


Surprise!
inside global.asa you can add a meta tag

<!--METADATA TYPE="TypeLib"
uuid={CD000000-8B95-11D1-82DB-00C04FB1625D}
-->

And now you have your constants imported.
I usually add the reference to create the procedure so I can use the code


Nov 13 '05 #10
VB/VBA will, under some circumstances, attempt to correct your
filename and version references: if you reference mydll ver 1.1.1
in your application folder, and on the target machine mydll
ver 1.1.2 is registered instead, and is in the Win Sys folder,
your application might attempt to use it. The critical link is
the GUID used to identify the object in the registry.

For example, if you try to load both Access 2002 and Access 2003,
you might find that you have actually loaded the A2003 version
or A2002 version of some file.

It often seems to cause problems: perhaps because we only notice
it when it has caused a problem.

(david)

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000 Library" (cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On his PC (in which there is no error and the code works fine), under references it says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References, it had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference to cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being swapped
out, and where the broken reference to cdo.dll came from?

Thanks!

Neil
"Egbert Nierop (MVP for IIS)" <eg***********@nospam.invalid> wrote in
message news:%2****************@TK2MSFTNGP11.phx.gbl...
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:N1****************@newsread1.news.pas.earthli nk.net...
I am using VBA/Access to send SMTP mail using CDO. I set a reference to
"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works
fine, both on my PC and on another PC. However, on another PC that the
database was installed on, the user is getting the message, "The project
contains a missing or broken reference to the file 'CDO.DLL' version
1.21." However, I don't have a reference to cdo.dll; my reference is to
cdosys.dll. The user has cdosys.dll, but doesn't have cdo.dll.

Any ideas as to what's going on?


Try
regsvr32 cdosys.dll
b.t.w. is the cdosys.dll exactly the same on both machines?
Thanks!

Neil


Nov 13 '05 #11
"Rick Brandt" <ri*********@hotmail.com> wrote in message
news:31*************@individual.net...

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:tC*****************@newsread3.news.pas.earthl ink.net...
One good thing about setting references is that it allows you specify an
order -- as with ADO and DAO -- with the first one being the default.

Anyway, so you're saying that if I omit the reference to CDO and just
keep the rest of the code the same, that it will automatically use the
library, as long as it's registered?
No, you do have to make some minor modifications to the code. Instead
of...

Dim CDOMsg as CDO.Message
Set CDOMsg = New CDO.Message

...you use...

Dim CDOMsg as Object
Set CDOMsg = CreateObject("CDO.Message")

You also can't use named constants that are defined in the external
library, but instead have to substitute the literal value.


Surprise!
inside global.asa you can add a meta tag

<!--METADATA TYPE="TypeLib"
uuid={CD000000-8B95-11D1-82DB-00C04FB1625D}
-->

And now you have your constants imported.
I usually add the reference to create the procedure so I can use the code


Nov 13 '05 #12
VB/VBA will, under some circumstances, attempt to correct your
filename and version references: if you reference mydll ver 1.1.1
in your application folder, and on the target machine mydll
ver 1.1.2 is registered instead, and is in the Win Sys folder,
your application might attempt to use it. The critical link is
the GUID used to identify the object in the registry.

For example, if you try to load both Access 2002 and Access 2003,
you might find that you have actually loaded the A2003 version
or A2002 version of some file.

It often seems to cause problems: perhaps because we only notice
it when it has caused a problem.

(david)

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000 Library" (cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On his PC (in which there is no error and the code works fine), under references it says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References, it had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference to cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being swapped
out, and where the broken reference to cdo.dll came from?

Thanks!

Neil
"Egbert Nierop (MVP for IIS)" <eg***********@nospam.invalid> wrote in
message news:%2****************@TK2MSFTNGP11.phx.gbl...
"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:N1****************@newsread1.news.pas.earthli nk.net...
I am using VBA/Access to send SMTP mail using CDO. I set a reference to
"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works
fine, both on my PC and on another PC. However, on another PC that the
database was installed on, the user is getting the message, "The project
contains a missing or broken reference to the file 'CDO.DLL' version
1.21." However, I don't have a reference to cdo.dll; my reference is to
cdosys.dll. The user has cdosys.dll, but doesn't have cdo.dll.

Any ideas as to what's going on?


Try
regsvr32 cdosys.dll
b.t.w. is the cdosys.dll exactly the same on both machines?
Thanks!

Neil


Nov 13 '05 #13
Yes; but in this case we're talking about different dlls altogether:
cdosys.dll being replaced with cdoex.dll in the application; and (in one
case) a broken reference to cdo.dll that I didn't place there!

Neil

"david epsom dot com dot au" <david@epsomdotcomdotau> wrote in message
news:41***********************@news.syd.swiftdsl.c om.au...
VB/VBA will, under some circumstances, attempt to correct your
filename and version references: if you reference mydll ver 1.1.1
in your application folder, and on the target machine mydll
ver 1.1.2 is registered instead, and is in the Win Sys folder,
your application might attempt to use it. The critical link is
the GUID used to identify the object in the registry.

For example, if you try to load both Access 2002 and Access 2003,
you might find that you have actually loaded the A2003 version
or A2002 version of some file.

It often seems to cause problems: perhaps because we only notice
it when it has caused a problem.

(david)

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000

Library"
(cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On

his
PC (in which there is no error and the code works fine), under references

it
says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll. But
when he used it, somehow the reference got changed to cdoex.dll, though
he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the
configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one
getting the error message. When we opened it up and looked at References,

it
had two things: first was the reference to cdoex.dll, as was on the other
one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC),
but it also added a broken reference to cdo.dll. We removed the reference

to
cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being
swapped
out, and where the broken reference to cdo.dll came from?

Thanks!

Neil
"Egbert Nierop (MVP for IIS)" <eg***********@nospam.invalid> wrote in
message news:%2****************@TK2MSFTNGP11.phx.gbl...
> "Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
> news:N1****************@newsread1.news.pas.earthli nk.net...
>>I am using VBA/Access to send SMTP mail using CDO. I set a reference to
>>"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works
>>fine, both on my PC and on another PC. However, on another PC that the
>>database was installed on, the user is getting the message, "The
>>project
>>contains a missing or broken reference to the file 'CDO.DLL' version
>>1.21." However, I don't have a reference to cdo.dll; my reference is to
>>cdosys.dll. The user has cdosys.dll, but doesn't have cdo.dll.
>>
>> Any ideas as to what's going on?
>
> Try
> regsvr32 cdosys.dll
> b.t.w. is the cdosys.dll exactly the same on both machines?
>
>> Thanks!
>>
>> Neil
>>
>



Nov 13 '05 #14
Have you checked the GUID values for those objects? I understand
the importance which you place on filenames, but that is not
actually how the system was intended to work.

(david)

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:iu*****************@newsread3.news.pas.earthl ink.net...
Yes; but in this case we're talking about different dlls altogether:
cdosys.dll being replaced with cdoex.dll in the application; and (in one
case) a broken reference to cdo.dll that I didn't place there!

Neil

"david epsom dot com dot au" <david@epsomdotcomdotau> wrote in message
news:41***********************@news.syd.swiftdsl.c om.au...
VB/VBA will, under some circumstances, attempt to correct your
filename and version references: if you reference mydll ver 1.1.1
in your application folder, and on the target machine mydll
ver 1.1.2 is registered instead, and is in the Win Sys folder,
your application might attempt to use it. The critical link is
the GUID used to identify the object in the registry.

For example, if you try to load both Access 2002 and Access 2003,
you might find that you have actually loaded the A2003 version
or A2002 version of some file.

It often seems to cause problems: perhaps because we only notice
it when it has caused a problem.

(david)

"Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
news:hK****************@newsread1.news.pas.earthli nk.net...
I just got some more information on this, and it's pretty interesting.

On my machine (development), I used "Microsoft CDO for Windows 2000

Library"
(cdosys.dll). Works fine.

The client using the db is in an office that uses Microsoft Exchange. On
his
PC (in which there is no error and the code works fine), under
references it
says, "Microsoft CDO for Microsoft Exchange" (cdoex.dll).

Now, when I delivered the database, the reference was to cdosys.dll.
But when he used it, somehow the reference got changed to cdoex.dll, though
he
didn't do anything.

So does Windows just pick which is the best cdo dll to use, based on the configuration? Since they're using Exchange, did it just replace the
reference to cdosys.dll with cdoex.dll? Seems kind of strange.

Anyway, getting back to the problem PC. Another PC on his LAN is the one getting the error message. When we opened it up and looked at References, it
had two things: first was the reference to cdoex.dll, as was on the
other one; and the second was a reference to "Microsoft CDO Version 1.21"
(cdo.dll), which was indicated as "Missing."

So this PC not only changed cdosys.dll to cdoex.dll (as on the other PC), but it also added a broken reference to cdo.dll. We removed the reference to
cdo.dll, and everything worked fine.

So, any idea as to what's going on, why these references are being
swapped
out, and where the broken reference to cdo.dll came from?

Thanks!

Neil
"Egbert Nierop (MVP for IIS)" <eg***********@nospam.invalid> wrote in
message news:%2****************@TK2MSFTNGP11.phx.gbl...
> "Neil Ginsberg" <nr*@nrgconsult.com> wrote in message
> news:N1****************@newsread1.news.pas.earthli nk.net...
>>I am using VBA/Access to send SMTP mail using CDO. I set a reference

to >>"Microsoft CDO for Windows 2000 Library" (cdosys.dll). Everything works >>fine, both on my PC and on another PC. However, on another PC that the >>database was installed on, the user is getting the message, "The
>>project
>>contains a missing or broken reference to the file 'CDO.DLL' version
>>1.21." However, I don't have a reference to cdo.dll; my reference is to >>cdosys.dll. The user has cdosys.dll, but doesn't have cdo.dll.
>>
>> Any ideas as to what's going on?
>
> Try
> regsvr32 cdosys.dll
> b.t.w. is the cdosys.dll exactly the same on both machines?
>
>> Thanks!
>>
>> Neil
>>
>



Nov 13 '05 #15

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

21 posts views Thread by tp | last post: by
8 posts views Thread by Rob Edwards | last post: by
2 posts views Thread by crushando | last post: by
8 posts views Thread by Akbur | last post: by
9 posts views Thread by paulmitchell507 | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.