Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 141
Default E-Mailing from Excel

I am trying to e-mail via code from Excel using a combination of Outlook
Express and Outlook. I have read Ron De Bruins excellent site but I have 2
things I want to incorporate and I can't see anything within the site, at
least not on the OE examples

1) I want to e-mail a workbook to email addresses that reside in AA1 and AA2
2) I want the Subject line of the e-mail to be whats in AA3


Thanks


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default E-Mailing from Excel

Hi John

See the Tips link on each example page
http://www.rondebruin.nl/mail/tips1.htm





--
Regards Ron de Bruin
http://www.rondebruin.nl


"John" wrote in message ...
I am trying to e-mail via code from Excel using a combination of Outlook Express and Outlook. I have read Ron De Bruins excellent
site but I have 2 things I want to incorporate and I can't see anything within the site, at least not on the OE examples

1) I want to e-mail a workbook to email addresses that reside in AA1 and AA2
2) I want the Subject line of the e-mail to be whats in AA3


Thanks




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 141
Default E-Mailing from Excel

Thanks Ron, exactly what I need, except now I have 2 problems

1) Excel97 crashes out with an exception error each time I run below,
doesn't with ExcelXP though

2) On one ExcelXP machine I get a "method sendmail object" error on line
MyArr = Sheets("E-Schedule").Range("AG1:AG3"), but on another machine
running XP its fine - damn!


Sub Mail_Reports()
Dim wb As Workbook
Dim strdate As String
Dim MyArr As Variant
strdate = Format(Now, "dd-mm-yy h-mm")
Application.ScreenUpdating = False
Sheets("E-Schedule").Visible = True
Sheets("E-Import").Visible = True
Sheets(Array("E-Schedule", "E-Import")).Copy
Set wb = ActiveWorkbook
With wb
.SaveAs ThisWorkbook.Name _
& " Sent on" & " " & strdate & ""
MyArr = Sheets("E-Schedule").Range("AG1:AG3")
.SendMail MyArr, Sheets("E-Schedule").Range("AG4").Value
.ChangeFileAccess xlReadOnly
Kill .FullName
.Close False
End With
Application.ScreenUpdating = True
Sheets(Array("E-Schedule", "E-Import")).Visible = False
Sheets("Home").Select
Range("A1").Select
End Sub




"Ron de Bruin" wrote in message
...
Hi John

See the Tips link on each example page
http://www.rondebruin.nl/mail/tips1.htm





--
Regards Ron de Bruin
http://www.rondebruin.nl


"John" wrote in message
...
I am trying to e-mail via code from Excel using a combination of Outlook
Express and Outlook. I have read Ron De Bruins excellent site but I have 2
things I want to incorporate and I can't see anything within the site, at
least not on the OE examples

1) I want to e-mail a workbook to email addresses that reside in AA1 and
AA2
2) I want the Subject line of the e-mail to be whats in AA3


Thanks






  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default E-Mailing from Excel

Hi John

I check out your problems this evening


--
Regards Ron de Bruin
http://www.rondebruin.nl


"John" wrote in message ...
Thanks Ron, exactly what I need, except now I have 2 problems

1) Excel97 crashes out with an exception error each time I run below, doesn't with ExcelXP though

2) On one ExcelXP machine I get a "method sendmail object" error on line MyArr = Sheets("E-Schedule").Range("AG1:AG3"), but on
another machine running XP its fine - damn!


Sub Mail_Reports()
Dim wb As Workbook
Dim strdate As String
Dim MyArr As Variant
strdate = Format(Now, "dd-mm-yy h-mm")
Application.ScreenUpdating = False
Sheets("E-Schedule").Visible = True
Sheets("E-Import").Visible = True
Sheets(Array("E-Schedule", "E-Import")).Copy
Set wb = ActiveWorkbook
With wb
.SaveAs ThisWorkbook.Name _
& " Sent on" & " " & strdate & ""
MyArr = Sheets("E-Schedule").Range("AG1:AG3")
.SendMail MyArr, Sheets("E-Schedule").Range("AG4").Value
.ChangeFileAccess xlReadOnly
Kill .FullName
.Close False
End With
Application.ScreenUpdating = True
Sheets(Array("E-Schedule", "E-Import")).Visible = False
Sheets("Home").Select
Range("A1").Select
End Sub




"Ron de Bruin" wrote in message ...
Hi John

See the Tips link on each example page
http://www.rondebruin.nl/mail/tips1.htm





--
Regards Ron de Bruin
http://www.rondebruin.nl


"John" wrote in message ...
I am trying to e-mail via code from Excel using a combination of Outlook Express and Outlook. I have read Ron De Bruins excellent
site but I have 2 things I want to incorporate and I can't see anything within the site, at least not on the OE examples

1) I want to e-mail a workbook to email addresses that reside in AA1 and AA2
2) I want the Subject line of the e-mail to be whats in AA3


Thanks








  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default E-Mailing from Excel

No problems for me in Excel 97

2) On one ExcelXP machine I get a "method sendmail object" error

Is the simple example1 macro working on that machine
http://www.rondebruin.nl/mail/folder1/mail1.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl


"Ron de Bruin" wrote in message ...
Hi John

I check out your problems this evening


--
Regards Ron de Bruin
http://www.rondebruin.nl


"John" wrote in message ...
Thanks Ron, exactly what I need, except now I have 2 problems

1) Excel97 crashes out with an exception error each time I run below, doesn't with ExcelXP though

2) On one ExcelXP machine I get a "method sendmail object" error on line MyArr = Sheets("E-Schedule").Range("AG1:AG3"), but on
another machine running XP its fine - damn!


Sub Mail_Reports()
Dim wb As Workbook
Dim strdate As String
Dim MyArr As Variant
strdate = Format(Now, "dd-mm-yy h-mm")
Application.ScreenUpdating = False
Sheets("E-Schedule").Visible = True
Sheets("E-Import").Visible = True
Sheets(Array("E-Schedule", "E-Import")).Copy
Set wb = ActiveWorkbook
With wb
.SaveAs ThisWorkbook.Name _
& " Sent on" & " " & strdate & ""
MyArr = Sheets("E-Schedule").Range("AG1:AG3")
.SendMail MyArr, Sheets("E-Schedule").Range("AG4").Value
.ChangeFileAccess xlReadOnly
Kill .FullName
.Close False
End With
Application.ScreenUpdating = True
Sheets(Array("E-Schedule", "E-Import")).Visible = False
Sheets("Home").Select
Range("A1").Select
End Sub




"Ron de Bruin" wrote in message ...
Hi John

See the Tips link on each example page
http://www.rondebruin.nl/mail/tips1.htm





--
Regards Ron de Bruin
http://www.rondebruin.nl


"John" wrote in message ...
I am trying to e-mail via code from Excel using a combination of Outlook Express and Outlook. I have read Ron De Bruins
excellent site but I have 2 things I want to incorporate and I can't see anything within the site, at least not on the OE
examples

1) I want to e-mail a workbook to email addresses that reside in AA1 and AA2
2) I want the Subject line of the e-mail to be whats in AA3


Thanks










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
I need to import my Excel Mailing list into mailing label format. Gord Dibben Excel Discussion (Misc queries) 0 November 5th 09 10:16 PM
I need to import my Excel Mailing list into mailing label format. Lyn Excel Discussion (Misc queries) 0 November 5th 09 08:11 PM
Excel mailing seandallen Excel Discussion (Misc queries) 0 February 3rd 07 09:46 PM
E-mailing From Excel Buttercup Excel Discussion (Misc queries) 1 October 2nd 06 03:27 PM
how do i convert MS Word mailing labels into an Excel mailing lis. unrhyll Excel Discussion (Misc queries) 1 February 4th 05 12:19 AM


All times are GMT +1. The time now is 06:23 PM.

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

About Us

"It's about Microsoft Excel"