简体   繁体   English

Excel通过Outlook自动发送电子邮件,随机不发送

[英]Excel Auto Send Emails via Outlook Randomly NOT Sending

I've inherited development of an Excel userform which contains a send button to return the user's data back to a central mailbox. 我继承了Excel用户窗体的开发,该窗体包含一个发送按钮,用于将用户的数据返回到中央邮箱。 The tool has just been rolled out to a larger community and some users are experiencing emails not being sent. 该工具刚刚推广到一个更大的社区,并且一些用户遇到了无法发送电子邮件的情况。 These are random events as the users can sometimes send the forms and it is not form specific. 这些是随机事件,因为用户有时可以发送表格,并且它不是特定于表格的。

The tool uses the following code to create the email: 该工具使用以下代码创建电子邮件:

Set ObjOL = CreateObject("Outlook.Application")
Set ObjOutMail = ObjOL.CreateItem(0)

and is sent via: 并通过以下方式发送:

ObjOutMail.send

We had tested this with a number of users and never had any problems, but we now have a number of users who have successfully sent 1 or more forms but 1 or more have also failed, and they also can't resend the successful forms any more either. 我们已经对许多用户进行了测试,但从未遇到任何问题,但是现在有许多用户已经成功发送了1个或多个表单,但有1个或多个表单也失败了,并且他们也无法重新发送成功的表单要么更多。

There are no error messages, the Outlook "this could be a virus, etc." 没有错误消息,Outlook“这可能是病毒等”。 confirmation is fired as usual (we have not attempted to circumvent this) but there is nothing in the 'Sent Items'. 确认照常进行(我们没有尝试绕过此确认),但“已发送邮件”中没有任何内容。 The users are also able to send conventionally generated emails so there is no mailbox limitations going on. 用户还能够发送常规生成的电子邮件,因此没有邮箱限制。

The Userform is modal and upon sending copies the three user fields to "Sheet1", saves itself and mails itself. 该用户窗体是模态的,并且在发送后将三个用户字段复制到“ Sheet1”,保存并发送邮件。

Really at a loss to understand what's going on. 了解发生的事情真是茫然。

Thanks for any advice. 感谢您的任何建议。

EDIT: To add we are still using Office 2003 on Win XP. 编辑:要添加,我们仍在Win XP上使用Office 2003。

Thanks for all the replies, using the .display property showed me what was up. 感谢所有答复,使用.display属性向我展示了最新情况。

The email is addressed to what I thought was an explicit address, however there is an extra '(MULTIUSER)' post fix which I didn;t realise was actually part of the address, DOH!. 电子邮件被发送到我认为是显式地址的位置,但是我没有发现一个额外的“(MULTIUSER)”后缀;我没有意识到实际上是该地址的一部分,DOH!。

Last week and similar mailbox made up of the same address but with a different postfix was added to the system. 上周,类似的邮箱由相同的地址组成,但具有不同的后缀,已添加到系统中。 This ment Outlook couldn't resolve the address and didn't send the emails. Outlook不能解析地址,也没有发送电子邮件。

Thanks again. 再次感谢。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM