ГлавнаяКомпьютерMicrosoft Outlook

Send Excel data in outlook body with borders

Просмотров 371
Добавлено: 14 дней назад
Встроить видео
0%
Добавьте следующий код на свою страницу, чтобы встроить это видео:
<iframe src="http://tng.pw/embed/237710/" width="650" height="405" frameborder="0"></iframe> <br />
<a href="http://tng.pw//237710/">Send Excel data in outlook body with borders</a>

Send Excel data in outlook body with borders
Send data from Excel to the body of your outlook email with the borders and colours.

The code
Sub esendtable()

Dim outlook As Object
Dim newEmail As Object
Dim xInspect As Object
Dim pageEditor As Object

Set outlook = CreateObject("Outlook.Application")
Set newEmail = outlook.CreateItem(0)

With newEmail
.To = Sheet1.Range("A2").Text
.CC = ""
.BCC = ""
.Subject = "Data"
.Body = "Please find the requested information" & vbCrLf & "Best Regards"
.display

Set xInspect = newEmail.GetInspector
Set pageEditor = xInspect.WordEditor

Sheet1.Range("B2:E5").Copy

pageEditor.Application.Selection.Start = Len(.Body)
pageEditor.Application.Selection.End = pageEditor.Application.Selection.Start
pageEditor.Application.Selection.PasteAndFormat (wdFormatPlainText)
.display
.Send
Set pageEditor = Nothing
Set xInspect = Nothing
End With

Set newEmail = Nothing
Set outlook = Nothing

End Sub

For more help visit my website http://www.easyexcelanswers.com or email me at easyexcelanswers@gmail.com.

I can customize this Excel application for your exact needs for a fixed price of $50. The work is normally returned within 24hrs.

I am able to provide online help on your computer at a reasonable rate.

MY videos are all created on Camtasia.
http://send.onenetworkdirect.net/z/582993/CD237560/

Follow me on Facebook
https://www.facebook.com/easyexcel.answers

Рекомендуем:

Microsoft Outlook
Добавлено: 619 дней назад