“这在我的错误例程中出现错误91”当调试时不使用错误例程 . 通过这种方式,您可以看到问题所在并可以说出问题所在 .

可能是

Set objCBP = objInsp.CommandBars.ActiveMenuBar.FindControl(, 30005)

见CommandBars.FindControl Method (Office) "The use of CommandBars in some Microsoft Office applications has been superseded by the new ribbon component of the Microsoft Office Fluent user interface."

可能这个:

Sub Mail_Outlook_With_Signature_Html_2()

' Don't forget to copy the function GetBoiler in the module.

' Working in Office 2000-2013

'Dim OutApp As Object

Dim OutMail As Object

Dim strbody As String

Dim SigString As String

Dim Signature As String

'Set OutApp = CreateObject("Outlook.Application")

'Set OutMail = OutApp.CreateItem(0)

Set OutMail = CreateItem(0)

strbody = "

Dear Customer Ron de Bruin

" & _

"Please visit this website to download the new version.
" & _

"Let me know if you have problems.
" & _

"Ron's Excel Page" & _

"Thank you"

'Change only Mysig.htm to the name of your signature

SigString = Environ("appdata") & _

"\Microsoft\Signatures\Mysig.htm"

If Dir(SigString) <> "" Then

Signature = GetBoiler(SigString)

Else

Signature = ""

End If

On Error Resume Next

With OutMail

'.To = "ron@debruin.nl"

.CC = ""

.BCC = ""

.Subject = "This is the Subject line"

.HTMLBody = strbody & "
" & Signature

'.Send

'or use

.Display

End With

On Error GoTo 0

Set OutMail = Nothing

'Set OutApp = Nothing

End Sub

Function GetBoiler(ByVal sFile As String) As String

'Dick Kusleika

Dim fso As Object

Dim ts As Object

Set fso = CreateObject("Scripting.FileSystemObject")

Set ts = fso.GetFile(sFile).OpenAsTextStream(1, -2)

GetBoiler = ts.readall

ts.Close

End Function

vba 添加outlook 签名_在Excel 2013中使用vba插入电子邮件签名相关推荐

  1. excel输入公式显示公式_在Excel 2013中使用FORMULATEXT显示公式

    excel输入公式显示公式 There is a new function in Excel 2013 – FORMULATEXT – that lets you show the text from ...

  2. excel怎么添加换行符_在Excel公式中添加换行符

    excel怎么添加换行符 在Excel公式中添加换行符 (Add Line Break in Excel Formula) It's easy to add a line break when you ...

  3. matlab条形图添加误差线_在Excel图表中添加误差线和对误差线进行设置的技巧

    在Excel图表中,误差线表示图形上相对于数据系列中每个数据点或数据标记的潜在误差量,其通常用于统计或科学记数法数据中,显示相对序列中的每个数据标记的潜在误差或不确定程度.本文介绍在Excel图表中添 ...

  4. excel表格末尾添加一行_在EXCEL表格中,快速插入多行、多列的技巧

    在使用Excel过程中,我们会遇到需要插入相同格式的多行或多列,如果一行行或一列列的插入,对于插入的数量较少的情况还是适用的.可是如果需要插入上百的行或列,使用此方法就比较费时费力啦.分享几个小技巧实 ...

  5. qt 表格中插入一行_在EXCEL表格中,快速插入多行、多列的技巧

    在使用Excel过程中,我们会遇到需要插入相同格式的多行或多列,如果一行行或一列列的插入,对于插入的数量较少的情况还是适用的.可是如果需要插入上百的行或列,使用此方法就比较费时费力啦.分享几个小技巧实 ...

  6. excel公式单元格注释_向Excel 2013中的公式和单元格添加注释

    excel公式单元格注释 When entering formulas in Excel, you may want to remind yourself, or someone else, what ...

  7. 在Excel 2013中创建圆形

    If a workbook has macros, or needs navigation buttons, I usually create a button by inserting a roun ...

  8. Excel 2013中单元格添加下拉列表的方法

    使用Excel录入数据的时候我们通常使用下拉列表来限定输入的数据,这样录入数据就很少发生错误了.Excel 2013较以前的版本发生了很大的变化,那么在Excel 2013是如何添加下拉列表的呢? 下 ...

  9. vba mysql 自动化错误_在Excel中运行VBA脚本时出现自动化错误

    在Excel 2007中运行VBA代码时出现自动化错误.我尝试连接到远程SQL Server数据库并将数据从Excel加载到SQL Server.在Excel中运行VBA脚本时出现自动化错误 我得到的 ...

  10. excel整列动态联动下拉_在Excel下拉列表中显示多列

    excel整列动态联动下拉 A data validation drop down list in Excel only shows one column of items. See how to s ...

最新文章

  1. Discuz!NT发帖回复后没有积分动画的去除和修复方法
  2. 部署在SAP ABAP服务器上的SAP UI5应用的JavaScript文件,是如何被SAP UI5 repository handler处理的
  3. Virtual Studio 2013 每次加载程序(dll)缓慢的问题
  4. Vue自定义属性的设置及获取
  5. python列表的排序方法_Python 列表 sort() 方法
  6. 苹果 M1 Pro 和 M1 Max 与原始 M1 相比性能如何?
  7. java接口的关键字_java关键字-interface
  8. Smart3D软件基本操作步骤
  9. 计网实验三 虚拟局域网 VLAN
  10. multisim怎么设置晶体管rbe_multisim晶体管
  11. php制作cms视频教程下载,phpcms下载频道的模板制作
  12. 【优化选址】基于遗传算法进行厂区布置优化附matlab代码
  13. dve 二维数组信号 显示波形_VCS-DVE
  14. Unity Cinemachine之第三人称摄像机CinemachineFreeLook属性详解
  15. 微软股价下跌 预示纳德拉与华尔街蜜月期终结?
  16. 微信在Ios上h5不能分享
  17. 百度百科:资金管理---现金为王
  18. HP 5200n 恢复工厂模式解决IP可ping通但无法打印故障
  19. 浅析绿萝算法下网站友链的交换策略和处理方法
  20. 图解外包验收流程V2.0及详细说明实例

热门文章

  1. Jmeter5.0脚本录制
  2. goredis文档中文翻译---Getting started with Golang Redis
  3. 具有强大的有限元网格ANSA
  4. 普天视PTS-3130C 模拟网络AHD监控 三维云台键盘 PELCO解析程序
  5. 三维全景从制作到上传
  6. linux下开发51单片机
  7. 计算机 服装生产管理的变化,服装生产与管理服装生产管理概述.ppt
  8. 上海企业英语培训机构排名
  9. Navivat 中快速快捷查找表和数据
  10. swfupload 无法加载_解决 KindEditor SWFUpload 批量上传检测用户登录状态的问题