John W. Colby
jcolby at ColbyConsulting.com
Tue Apr 29 10:11:05 CDT 2003
Dave, I am able to send email, attach files etc. The problem is that with anything past SP1a, MS put a "security fix" in place that pops up a "warning" that "some program is trying to send emails from outlook, do you want to allow this". Obviously this is designed to prevent viruses from sending emails - forces the user to see and ok the email being sent. But in this case, it is just a PITA since "of course they want to allow this". John W. Colby Colby Consulting www.ColbyConsulting.com -----Original Message----- From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of davesharpe2 at cox.net Sent: Tuesday, April 29, 2003 11:01 AM To: accessd at databaseadvisors.com Subject: Re: [AccessD] Outlook's annoying habits ----- Original Message ----- From: John W. Colby To: AccessD Sent: Monday, April 28, 2003 8:43 AM Subject: [AccessD] Outlook's annoying habits I have a database that needs to send emails every day with attached docs. With all SPs applied, Outlook insists on stopping the process and forcing the user to confirm the send. Is there any way to turn off this annoying process? John W. Colby Colby Consulting www.ColbyConsulting.com ******************************************************* John - I'm not sure of the significance of "With all SPs applied". I'm Office2000 not sure of SP level. I use the following ( I found the basic format somewhere, sometime ago ). It works for me without any prompting, I hope that It might help you. Dave ******************************************************** Function Send_To_Them(TheFile As String) Dim CheckOutlook As Boolean DoCmd.Hourglass True Dim The_Subj As String The_Subj = "Here is the weekly VINA data" Dim B_B As String B_B = "Folks, attached is the VINA current as of moments ago." & vbCrLf & vbCrLf B_B = B_B & vbCrLf B_B = B_B & "Dave Sharpe" & vbCrLf Dim objOutlook As Outlook.Application Dim objOutlookMsg As Outlook.MailItem Dim objOutlookRecip As Outlook.Recipient Dim objOutlookAttach As Outlook.Attachment ' Create the Outlook session. Set objOutlook = CreateObject("Outlook.Application") ' Create the message. Set objOutlookMsg = objOutlook.CreateItem(olMailItem) With objOutlookMsg ' Add the To recipient(s) to the message. Set objOutlookRecip = .Recipients.Add("_vina_real") objOutlookRecip.Type = olTo ' Add the BCC recipient(s) to the message. Set objOutlookRecip = .Recipients.Add("_mee") objOutlookRecip.Type = olBCC ' Set the Subject, Body, and Importance of the message. .Subject = The_Subj .Body = B_B .Importance = olImportanceHigh 'High importance ' Add attachments to the message. If Not IsMissing(TheFile) Then Set objOutlookAttach = .Attachments.Add(TheFile) End If ' Resolve each Recipient's name. For Each objOutlookRecip In .Recipients objOutlookRecip.Resolve Next ' Should we look at the message in Outlook before sending? If CheckOutlook Then .Display Else .Save .Send End If End With Set objOutlook = Nothing DoCmd.Hourglass False End Function '======================================================================== '======================================================================== _______________________________________________ AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com ----------------------------------------------------- eMailBoss puts you in command of your email. Get your copy today at http://www.eMailBoss.com -------------- next part -------------- A non-text attachment was scrubbed... Name: winmail.dat Type: application/ms-tnef Size: 3276 bytes Desc: not available URL: <http://databaseadvisors.com/pipermail/accessd/attachments/20030429/bcb532d1/attachment-0001.bin>