If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Answer an Outlook Express message box
I have some VBL code that copies a specific worksheet from a workbook then
emails it. Is it possible to alter the code to answer an Outlook Express message box that asks if I want to send the message This the code that works well, except for the box that comes up Kill "C:\Documents and Settings\Compaq_Administrator\My Documents\Pay Slips\Book2.xls" Sheets("Pay Slip").Visible = True Sheets("Pay Slip").Select Sheets("Pay Slip").Copy Range("A1:G17").Select Selection.Copy Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Range("a1").Select ActiveWorkbook.SaveAs Filename:= _ "C:\Documents and Settings\Compaq_Administrator\My Documents\Pay Slips\Book2.xls", _ FileFormat:=xlExcel8, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:=False, CreateBackup:=False ActiveWorkbook.SendMail ", Subject:="Hi" ActiveWorkbook.Close SaveChanges:=False Sheets("Pay Slip").Select Sheets("Pay Slip").Visible = False |
#2
|
|||
|
|||
Answer an Outlook Express message box
Hi ozhunter
See http://www.rondebruin.nl/mail/prevent.htm -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "ozhunter" wrote in message ... I have some VBL code that copies a specific worksheet from a workbook then emails it. Is it possible to alter the code to answer an Outlook Express message box that asks if I want to send the message This the code that works well, except for the box that comes up Kill "C:\Documents and Settings\Compaq_Administrator\My Documents\Pay Slips\Book2.xls" Sheets("Pay Slip").Visible = True Sheets("Pay Slip").Select Sheets("Pay Slip").Copy Range("A1:G17").Select Selection.Copy Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Range("a1").Select ActiveWorkbook.SaveAs Filename:= _ "C:\Documents and Settings\Compaq_Administrator\My Documents\Pay Slips\Book2.xls", _ FileFormat:=xlExcel8, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:=False, CreateBackup:=False ActiveWorkbook.SendMail ", Subject:="Hi" ActiveWorkbook.Close SaveChanges:=False Sheets("Pay Slip").Select Sheets("Pay Slip").Visible = False |
Thread Tools | |
Display Modes | |
|
|