他是一个小问题,但令我感到困惑。我正在自动发送从excel发送的电子邮件。由于某种原因,下面的代码使最后一行的间距大于正常间距:
Sub emailspacing()
Dim OutApp As Object
Dim OutMail As Object
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
With OutMail
.HTMLBody = "<p style='font-family:calibri;font-size:14.5'>Thanks for your help</p>"
.display
End With
然而,当我删除P样式部分时,生成的电子邮件具有完美的行间距???
Sub emailspacing()
Dim OutApp As Object
Dim OutMail As Object
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
With OutMail
.HTMLBody = "Thanks for your help"
.display
End With
有没有人知道将风格化HTML文本与正常行间距合并的方法?
答案 0 :(得分:1)
破解了!这需要添加到p样式:
边距:.0001pt;