Hi All,
This problem was created the last time I took a day off (IT came in and installed access 2003 on both of my PC's, destroying a lot of functionality in my applications). I have been working overtime to get these apps ready for my next days off, which start today. They are in good shape except for one thing (which obviously won't be fixed until I get back on Friday, so users will be dealing with sending the email manually).
With the new install, access seems unable to find the Outlook reference library. I am really stuck on this one, I had a whole bunch of subs that sent email automatically and none of them work anymore. Any advice you could give on this would be greatly appreciated, although it will not save my users the hassle of sending emails manually the next few days. Thanks in advance for your help, and here is the code if that helps:
This problem was created the last time I took a day off (IT came in and installed access 2003 on both of my PC's, destroying a lot of functionality in my applications). I have been working overtime to get these apps ready for my next days off, which start today. They are in good shape except for one thing (which obviously won't be fixed until I get back on Friday, so users will be dealing with sending the email manually).
With the new install, access seems unable to find the Outlook reference library. I am really stuck on this one, I had a whole bunch of subs that sent email automatically and none of them work anymore. Any advice you could give on this would be greatly appreciated, although it will not save my users the hassle of sending emails manually the next few days. Thanks in advance for your help, and here is the code if that helps:
Code:
Private Sub EmailYankee_Click()
Dim objOutlook As Outlook.Application
Dim ItmNewEmail As Outlook.MailItem
Dim filedate, fnamedate As String
Dim fdir As String
Dim title As String
Dim OutputFileName As String
filedate = Date
fnamedate = Format(filedate, "mmddyy")
OutputFileName = "Reports" & fnamedate & ".zip"
fdir = "some\dir\"
Set objOutlook = CreateObject("Outlook.Application")
Set ItmNewEmail = objOutlook.CreateItem(olMailItem)
With ItmNewEmail
.To = "emails"
.CC = "emails"
.Subject = "Subject" & filedate
.Body = "Attached please find today's reports. Please notify (user) if you have any questions." & Chr(13) & Chr(13) & "Thank You."
.Attach = fdir & OutputFileName
.Send ' send files and notification
End With
End Sub
It's a magical time of year in Philadelphia. Eagles training camp marks the end of another brutal season of complaining about the Phillies.