自动在电子邮件中打开链接的Outlook脚本 [英] outlook script that automatically opens links in emails

查看:194
本文介绍了自动在电子邮件中打开链接的Outlook脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在PC上使用的是Windows 10,大多数时候都使用chrome进行Outlook.我正在尝试获取一个脚本,该脚本会自动打开电子邮件中收到的链接.我发现了VBA脚本,但它们不起作用,我一直收到错误消息.你们中的任何一个可以帮助我吗?

I am using windows 10 on my pc and use chrome most of the time for outlook. I am trying to get a script that automatically opens a link received in a email. I have found vba scripts but they do not work i keep getting errors. If any of you could help me out with this?

推荐答案

您可以使用MailItem类的HTMLBody属性在此处查找所有超链接.然后,您可以使用以下方法通过找到的链接运行Chrome:

You can use the HTMLBody property of the MailItem class to find all hyperlinks there. Then you can use the following method to run Chrome with a link found:

Sub LaunchInChrome (url as String)
  Dim chromePath As String
  chromePath = """C:\Program Files\Google\Chrome\Application\chrome.exe"""
  Shell (chromePath & " -url " & url)
End Sub

这篇关于自动在电子邮件中打开链接的Outlook脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆