![]() |
sending automatic email with VBA-Excel in Vista OS and Windows Mail
This will only work if you use Outlook
For Windows Mail use SendMail (see the first section of this page) http://www.rondebruin.nl/sendmail.htm Or use CDO -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Alain Bernard" wrote in message ... Hi, The following code run perfectly with Windows2000 and Outlook. Using Vista OSa nd Windows Mail that doesn't work any more. Is there a specific library to select ? or Is there a different code ? Set myMailApp = CreateObject("Outlook.Application") Set myMail = myMailApp.CreateItem(olMailItem) With myMail .To = " .Subject = "test" .Body = "test" '.Attachments.Add Path & "\" & File .ReadReceiptRequested = True .Display End With Could any body send me back information to adapt this code in my environment ? Thank you in advance. Alain |
sending automatic email with VBA-Excel in Vista OS and Windows Mail
Thank you to Ron de Bruin for his help.
I need more precisions. In CDO context the .Display method does'nt exists and I have not found the methods to attach a file to my mail and to view it before sending it. I have already include the "Microsoft CDO for Windows 2000 library" but there is'nt any description of all methods and properties of these functions. How to get these descriptions ? Reading some tips about CDO methods I tested the option .Send showDialog:=True without success. Thank you in advance for your help. "Ron de Bruin" a écrit dans le message de ... This will only work if you use Outlook For Windows Mail use SendMail (see the first section of this page) http://www.rondebruin.nl/sendmail.htm Or use CDO -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Alain Bernard" wrote in message ... Hi, The following code run perfectly with Windows2000 and Outlook. Using Vista OSa nd Windows Mail that doesn't work any more. Is there a specific library to select ? or Is there a different code ? Set myMailApp = CreateObject("Outlook.Application") Set myMail = myMailApp.CreateItem(olMailItem) With myMail .To = " .Subject = "test" .Body = "test" '.Attachments.Add Path & "\" & File .ReadReceiptRequested = True .Display End With Could any body send me back information to adapt this code in my environment ? Thank you in advance. Alain |
sending automatic email with VBA-Excel in Vista OS and Windows Mail
As far as I know it is not possible to view the mail before you send it with CDO
Use the SendMail code and not fill in the To Like this .SendMail "", "This is the Subject line" -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Alain Bernard" wrote in message ... Thank you to Ron de Bruin for his help. I need more precisions. In CDO context the .Display method does'nt exists and I have not found the methods to attach a file to my mail and to view it before sending it. I have already include the "Microsoft CDO for Windows 2000 library" but there is'nt any description of all methods and properties of these functions. How to get these descriptions ? Reading some tips about CDO methods I tested the option .Send showDialog:=True without success. Thank you in advance for your help. "Ron de Bruin" a écrit dans le message de ... This will only work if you use Outlook For Windows Mail use SendMail (see the first section of this page) http://www.rondebruin.nl/sendmail.htm Or use CDO -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "Alain Bernard" wrote in message ... Hi, The following code run perfectly with Windows2000 and Outlook. Using Vista OSa nd Windows Mail that doesn't work any more. Is there a specific library to select ? or Is there a different code ? Set myMailApp = CreateObject("Outlook.Application") Set myMail = myMailApp.CreateItem(olMailItem) With myMail .To = " .Subject = "test" .Body = "test" '.Attachments.Add Path & "\" & File .ReadReceiptRequested = True .Display End With Could any body send me back information to adapt this code in my environment ? Thank you in advance. Alain |
All times are GMT +1. The time now is 08:11 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com