VBA CDO Email Automation .send freeze

2019-07-27 10:42发布

I have tried search everywhere for an answer on this as I can't believe it has only happened to me but can't seem to find anything.

I have a standard CDO email send function that works fine and up to about 3 months ago could reel off sending about 250 emails in probably less than 5 minutes. This was working off exchange 2003.

Then we upgraded our exchange server to 2010 and now my function that hasn't changed (apart from the ip address of the smtp server) pauses on the .send portion for around 15-30 seconds. I can only think this is something that has changed on the exchange end of things as I haven't changed anything but it makes the same macro take up to 2-4 hours to send all the emails now.

Has anyone else experienced this or know of what needs to be fixed on exchange to allow me to make my nice reports run quickly again?

Many Thanks

1条回答
倾城 Initia
2楼-- · 2019-07-27 11:24

Exchange 2010 Receive Connectors must be configured to receive incoming SMTP email, by default they will not otherwise there would be an open mail relay.

I suggest you verify the server will accept incoming SMTP from the workstation by opening a TELNET connection to the email server port 25 and try to manually send an email, for example:

  C: HELO myComputerName
  S: 250 smtp.theserverside.net Hello myComputerName [...] 
  C: MAIL FROM: me@TheServerSide.net
  S: 250 smtp.TheServerSide.net <me@TheServerSide.net> is syntactically correct 
  C: RCPT TP: you@TheServerSide.net
  S: 250 <you@TheServerSide.net> verified 
  C: DATA 
  S: 354 Enter message, ending with "." on a line by itself 
  C: Date: 1 April 04 10:30:42
  C: From: me@TheServerSide.net
  C: To: you@TheServerSide.net
  C: Subject: Say Hello
  C: Hello my friend! 
  C: And good bye! 
  C: . 
  S: 250 OK ID=1B3alH-0004ue-00 
  C: QUIT 
  S: 221 smtp.TheServerSide.net closing connection

If you need to make adjustments on Exchange be careful and test. The receive connectors are at Microsoft Exchange Management Console/MS Exchange On-Prem/Server Configuration/Hub Transport

查看更多
登录 后发表回答