Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 109
Default send file by e-mail

I am new to sending files automatically and am having trouble setting the
message body text.

I want three lines of text (with a blank line between them) and then the
attachment.

I have been trying to use the following:

Dim strbody As String
strbody = "Line 1" & vbNewLine & vbNewLine & _
"Line 2" & vbNewLine & vbNewLine & _
"Line 3

And then putting .Body = strbody

The text all appears OK but the attachment (which has a long file name)
'joins' itself to the end of line 3 text. Is there any way around this?

Gareth



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default send file by e-mail

try

strbody = "Line 1" & vbNewLine & vbNewLine & _
"Line 2" & vbNewLine & vbNewLine & _
"Line 3 & vbNewLine & vbNewLine

--
Regards,
Tom Ogilvy


Gareth wrote in message
...
I am new to sending files automatically and am having trouble setting the
message body text.

I want three lines of text (with a blank line between them) and then the
attachment.

I have been trying to use the following:

Dim strbody As String
strbody = "Line 1" & vbNewLine & vbNewLine & _
"Line 2" & vbNewLine & vbNewLine & _
"Line 3

And then putting .Body = strbody

The text all appears OK but the attachment (which has a long file name)
'joins' itself to the end of line 3 text. Is there any way around this?

Gareth





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel - Sending file using File/Send to/Mail Recipient Dawn Excel Discussion (Misc queries) 0 March 21st 10 09:24 PM
Excel - Sending file using File/Send to/Mail Recipient Dawn Excel Discussion (Misc queries) 0 March 21st 10 09:20 PM
How do I only send 1 worksheet of a file in an e-mail? JeffL Excel Worksheet Functions 1 April 15th 09 05:27 PM
Send e-mail from a Excel file Freshman Excel Worksheet Functions 5 March 24th 08 06:08 PM
File-Send To-Mail Recipient (for Review) Frans van Zelm Excel Discussion (Misc queries) 1 December 25th 04 06:43 PM


All times are GMT +1. The time now is 02:25 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"