CDO question

  • Permalink
  • submit to reddit
  • Email
  • Follow


I am testing CDO for email. The following function works on one computer but
fails on the second computer with a messgage that "the server response was
not available".

Both computers are on the same network and can send a receive email from the
account I am using. The program compiles OK on both computers but some
reason I can't figure out, it fails on the second computer.

Public Function SendEmailUsingCDO()

' 11/4/03 worked on E2
' 10/25/04 works on E2 but won't work here on E1 ????
' on form or as as this function

Dim iMsg As New CDO.Message
Dim iConf As New CDO.Configuration

With iConf.Fields

  .Item(cdoSendUsingMethod) = cdoSendUsingPort

  .Item(cdoSMTPServer) = "smtp.comcast.net"
  .Item(cdoSMTPConnectionTimeout) = 15 ' quick timeout
  .Item(cdoSMTPAuthenticate) = cdoBasic
  .Item(cdoSendUserName) = "xxxxxx"
  '.Item(cdoSendPassword) = "xxxxxx"
  '.Item(cdoURLProxyServer) = "server:80"
  '.Item(cdoURLProxyBypass) = "<local>"
  '.Item(cdoURLGetLatestVersion) = True

  '.Update
End With

With iMsg
  Set .Configuration = iConf
      .To = """User A"" <xxx@xxx.net>"
      .From = "<xxxxx@xxx.us>"
      '.From = """User B"" <xxxx@comcast.net>"
      .Subject = "Access CDO test"
      '.BCC = "<xxxx@xxx.us>" never recd with/without <>
      '.CreateMHTMLBody "http://mypage"
      '.AddAttachment "C:\files\mybook.doc"
      '.
      .TextBody = "This is the body of the CDO message"
      .Send
End With

End Function


0
Reply 88karl3200 (58) 10/26/2004 2:36:01 PM

See related articles to this posting

> I am testing CDO for email. The following function works on one computer
but
> fails on the second computer with a messgage that "the server response was
> not available".
>
> Both computers are on the same network and can send a receive email from
the
> account I am using. The program compiles OK on both computers but some
> reason I can't figure out, it fails on the second computer.
>
> Public Function SendEmailUsingCDO()
>
> ' 11/4/03 worked on E2
> ' 10/25/04 works on E2 but won't work here on E1 ????
> ' on form or as as this function
>
> Dim iMsg As New CDO.Message
> Dim iConf As New CDO.Configuration
>
> With iConf.Fields
>
>   .Item(cdoSendUsingMethod) = cdoSendUsingPort
>
>   .Item(cdoSMTPServer) = "smtp.comcast.net"
>   .Item(cdoSMTPConnectionTimeout) = 15 ' quick timeout
>   .Item(cdoSMTPAuthenticate) = cdoBasic
>   .Item(cdoSendUserName) = "xxxxxx"
>   '.Item(cdoSendPassword) = "xxxxxx"
>   '.Item(cdoURLProxyServer) = "server:80"
>   '.Item(cdoURLProxyBypass) = "<local>"
>   '.Item(cdoURLGetLatestVersion) = True
>
>   '.Update
> End With
>
> With iMsg
>   Set .Configuration = iConf
>       .To = """User A"" <xxx@xxx.net>"
>       .From = "<xxxxx@xxx.us>"
>       '.From = """User B"" <xxxx@comcast.net>"
>       .Subject = "Access CDO test"
>       '.BCC = "<xxxx@xxx.us>" never recd with/without <>
>       '.CreateMHTMLBody "http://mypage"
>       '.AddAttachment "C:\files\mybook.doc"
>       '.
>       .TextBody = "This is the body of the CDO message"
>       .Send
> End With
>
> End Function
>
have you added the refernces CDO ?
MAssimiliano


0
Reply master8346 (24) 10/27/2004 2:09:38 PM

Yes I have the CDO reference (it says Microsoft CDO for Windows 2000
Library) . I'm using XP on both machines.

-- "MA" <master@massimilianoamendola.it> wrote in message
news:0_Nfd.28331$B06.15852@news.edisontel.com...
> > I am testing CDO for email. The following function works on one computer
> but
> > fails on the second computer with a messgage that "the server response
was
> > not available".
> >
> > Both computers are on the same network and can send a receive email from
> the
> > account I am using. The program compiles OK on both computers but some
> > reason I can't figure out, it fails on the second computer.
> >
> > Public Function SendEmailUsingCDO()
> >
> > ' 11/4/03 worked on E2
> > ' 10/25/04 works on E2 but won't work here on E1 ????
> > ' on form or as as this function
> >
> > Dim iMsg As New CDO.Message
> > Dim iConf As New CDO.Configuration
> >
> > With iConf.Fields
> >
> >   .Item(cdoSendUsingMethod) = cdoSendUsingPort
> >
> >   .Item(cdoSMTPServer) = "smtp.comcast.net"
> >   .Item(cdoSMTPConnectionTimeout) = 15 ' quick timeout
> >   .Item(cdoSMTPAuthenticate) = cdoBasic
> >   .Item(cdoSendUserName) = "xxxxxx"
> >   '.Item(cdoSendPassword) = "xxxxxx"
> >   '.Item(cdoURLProxyServer) = "server:80"
> >   '.Item(cdoURLProxyBypass) = "<local>"
> >   '.Item(cdoURLGetLatestVersion) = True
> >
> >   '.Update
> > End With
> >
> > With iMsg
> >   Set .Configuration = iConf
> >       .To = """User A"" <xxx@xxx.net>"
> >       .From = "<xxxxx@xxx.us>"
> >       '.From = """User B"" <xxxx@comcast.net>"
> >       .Subject = "Access CDO test"
> >       '.BCC = "<xxxx@xxx.us>" never recd with/without <>
> >       '.CreateMHTMLBody "http://mypage"
> >       '.AddAttachment "C:\files\mybook.doc"
> >       '.
> >       .TextBody = "This is the body of the CDO message"
> >       .Send
> > End With
> >
> > End Function
> >
> have you added the refernces CDO ?
> MAssimiliano
>
>


0
Reply 88karl3200 (58) 10/27/2004 3:07:50 PM
comp.databases.ms-access 42166 articles. 10 followers. Post

2 Replies
61 Views

Similar Articles

[PageSpeed] 52

  • Permalink
  • submit to reddit
  • Email
  • Follow


Reply:

Similar Artilces:

Visual Basic 6 and MAPI / CDO 1.21 question
hi group, Can anyone explain what they are talking about in this paragraph? Note: When you access an element of the Categories array, whether to read it or write it, you must include an extra set of parentheses to satisfy the Visual Basic compiler's allowance for a property parameter: from this MSDN page (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cdo/html/_ olemsg_objects.2c_.properties.2c_.and_methods.asp) What do they mean by "Visual Basic compiler's allowance for a property parameter" ? Thanks in advance, Kelly Greer kellygreer1@nospam.c...

Questions, questions & more questions
Hi all, As I've got rather a lot of questions to post I thought I'd better merge a few into one post. Appreciate these have probably been asked stacks of times but research on the net has not turned up the answers. What's the quickest solution for transferring files from a PC to an Falcon/TT? I'm going to look into networking my Atari kit but that's a little way off at the moment. Is the Backwards ST emulator program still available? Would love to play some of my old favourites such as Megalomania. I know that I could use a PC emulator but somehow that...

Questions, Questions...
Hi! I took the routine from Gastronor.mdb: In the frmOrderDetails -> ITemID_AfterUpdate: Dim strFilter as String strFilter = "ItemID = " & Me!ItemID but it didn't work on win 2000 with access 2000. However, after playing around for a while, I found: Me!UnitPrice = ItemID.Column(2) to work just fine, even after updating prices in the tblItems. Anybody knows why? The routine in win 98/win nt in the footer of frmOrderDetails: =Sum((Price*Amount*(1-[Discount])/100)*100)) didn't either work. After testing and trying I finally discovered that =Sum(Price*Amount*Discount)...

Questions that question????
Hi everybody, I am thinking abt how much information can be provided to a quetion posted related to design with emerging hitech FPGA's.I started using this usenet just a few weeks ago,and I find it very interesting to notice people with great experience working in industries or with FPGA manufacuturers replying to the best they could.So I started thinking, how much of an information related to the desing should be given for a question. The less information i give, i likely to get no repliess, and the more i give , i might loose my valuable design , what would be a tradeoff here? So, how ...

Questions over questions
Hello people, I have a problem with my ISP! He kills my php script, if they were executed over 30 seconds. Can I use some trick to fake a little bit? That I can execute the script longer!? Greeting! Sven Dzepina wrote: > Hello people, > > I have a problem with my ISP! He kills my php script, if they were executed > over 30 seconds. > Can I use some trick to fake a little bit? That I can execute the script > longer!? > > Greeting! > > If your ISP doesn't run your script in safe mode, which it most likely does, then you can set_time_limit(0); for unli...

Question about a question
Steve Pampling: Steve, do you take a.a.bugs? I need a smidgin of advice about a particular Win PC question, it needs putting to a Sys/IT maintenance/admin type person rather than any old idiot like me. If you don't sub to ..bugs can I please email you privately, as I did around Christmas time (same old computer)? Cheers Dave S -- In article <4e2368520fdfs@ukgateway.net>, Dave Symes <dfs@ukgateway.net> wrote: > Steve Pampling: > Steve, do you take a.a.bugs? Nope. I vaguely recall it being on a list some time ago (years) but I shortened things to the core csa and ...

Questions, Questions, Questions -- Well, really only two
This newsgroup seemed distribution non-specific so here goes: 1. Many companies who want to use linux, want it for email and web service. These systems don't need xwindows, and, in fact, as I understand it, not installing it not only saves resources but reduces security risk. Is there anywhere freely available a how-to install various current distributions of linux using text only, and installing mail, web and domain name service that is fairly easy for the uninformed to follow? Especially helpful would be a debian install. 2. Does anyone know of an encyclopedia, preferrably text-b...

Question and bonus question
Given an integer between 0 and 5000 (characters 0-9; no leading zero) can anyone suggest a non-iterative, non-recursive way of summing the individual digits? I'm just looking for a clever way to do what is easy with the obvious loop: Sum = 0 Do I = 1 to length(n) Sum = sum + substr(n,I,1) End Bonus Question: Can anyone suggest a mechanism to allow reading the TOC (Table of Content) of an Audio CD? The connection? The TOC contains frame numbers where each track starts. Do an integer divide by 75 and you get the time offset in seconds. Sum the digits of each of the start times...

questions on audit question
I want to audit any insert, update transaction on a particular table. So I set audit_trail=DB then "audit insert, update on db1.tablename;" >From the SYS.AUD$ table, the result only shows ONE audit record for each session. For example, if UserA do 2 INSERTS and 3 UPDATES on the table during the session, I only got ONE record in SYS.AUD$: SQL> select userid, ses$actions from user_audit_object; USERA ------S---S----- But I want to see the exact number of times the tables are being insert and update. How to accomplish that? Susan susana73@hotmail.com wrote: &g...