By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,662 Members | 1,765 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,662 IT Pros & Developers. It's quick & easy.

SendObject Woes

P: n/a
jmr
Hi

- I made a macro to send a report as an attachment to an e-mail in Access
97

- I got the macro to work on WinMe with Netscape as long as the To: field
was not filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check Your
Mail Application to Make Sure That It's Working Properly."
Q283173 http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.
Nov 12 '05 #1
Share this Question
Share on Google+
7 Replies


P: n/a
Have you tried the fix that is shown in the KB article you included as a reference?
__________________________________________________ ______

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Hi

- I made a macro to send a report as an attachment to an e-mail in Access
97

- I got the macro to work on WinMe with Netscape as long as the To: field
was not filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check Your
Mail Application to Make Sure That It's Working Properly."
Q283173 http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.
Nov 12 '05 #2

P: n/a
jmr
Yes, I followed all steps in the article, but the registry
entry did not exist on my computer.

On Sat, 25 Oct 2003 13:35:28 -0700, Tom Wickerath
<AO***********************@comcast.net> wrote:
Have you tried the fix that is shown in the KB article you included as a
reference?
__________________________________________________ ______

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Hi

- I made a macro to send a report as an attachment to an e-mail in
Access
97

- I got the macro to work on WinMe with Netscape as long as the To:
field
was not filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check
Your
Mail Application to Make Sure That It's Working Properly."
Q283173 http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.


--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
Nov 12 '05 #3

P: n/a
Try creating this key as a new entry in your registry.
__________________________________________________ ______

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Yes, I followed all steps in the article, but the registry
entry did not exist on my computer.

On Sat, 25 Oct 2003 13:35:28 -0700, Tom Wickerath
<AO***********************@comcast.net> wrote:
Have you tried the fix that is shown in the KB article you included as a
reference?
__________________________________________________ ______

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Hi

- I made a macro to send a report as an attachment to an e-mail in
Access
97

- I got the macro to work on WinMe with Netscape as long as the To:
field
was not filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check
Your
Mail Application to Make Sure That It's Working Properly."
Q283173 http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.


--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
Nov 12 '05 #4

P: n/a
jmr
I added the key, but I did not have any values to
put into it. With just adding the key, the problem
was not solved. I still get the "Microsoft Access
Can't Open the Mail Session. Check Your Mail
Application to Make Sure That It's Working Properly."
error message.

Does anyone know what values are supposed to be
under the key?
On Mon, 27 Oct 2003 09:20:53 -0800, Tom Wickerath
<AO***********************@comcast.net> wrote:
Try creating this key as a new entry in your registry.
__________________________________________________ ______

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Yes, I followed all steps in the article, but the registry
entry did not exist on my computer.

On Sat, 25 Oct 2003 13:35:28 -0700, Tom Wickerath
<AO***********************@comcast.net> wrote:
Have you tried the fix that is shown in the KB article you included as a
reference?
__________________________________________________ ______

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Hi

- I made a macro to send a report as an attachment to an e-mail in
Access
97

- I got the macro to work on WinMe with Netscape as long as the To:
field
was not filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check
Your
Mail Application to Make Sure That It's Working Properly."
Q283173
http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.



--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
Nov 12 '05 #5

P: n/a
Oops, I had not gone back to the KB article....since it states to delete the key, my
earlier suggestion to creating this key really makes no sense.

______________________________________

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...

I added the key, but I did not have any values to
put into it. With just adding the key, the problem
was not solved. I still get the "Microsoft Access
Can't Open the Mail Session. Check Your Mail
Application to Make Sure That It's Working Properly."
error message.

Does anyone know what values are supposed to be
under the key?

______________________________________

On Mon, 27 Oct 2003 09:20:53 -0800, Tom Wickerath
<AO***********************@comcast.net> wrote:

Try creating this key as a new entry in your registry.
______________________________________

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Yes, I followed all steps in the article, but the registry
entry did not exist on my computer.
______________________________________

On Sat, 25 Oct 2003 13:35:28 -0700, Tom Wickerath
<AO***********************@comcast.net> wrote:

Have you tried the fix that is shown in the KB article you included as a
reference?
______________________________________

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...

Hi

- I made a macro to send a report as an attachment to an e-mail in Access 97
- I got the macro to work on WinMe with Netscape as long as the To: field was not
filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check Your Mail Application
to Make Sure That It's Working Properly."Q283173
http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.
Nov 12 '05 #6

P: n/a
jmr
Here's the scoop

I tried to install a mapi compliant email program,
eudora 6, but the error still came up.
Next I installed Outlook from the Office 97 disk
and the error is gone, but now I have to figure out
Microsoft Exchange, but when I try to get the
Microsoft knowledge base article on that, the
knowledge base search page is down.

I may have to install Microsoft Exchange or other
stuff, but I will tackle that later in the day.

Thanks for all your ideas.

On Mon, 27 Oct 2003 19:33:30 -0800, Tom Wickerath
<AO***********************@comcast.net> wrote:
Oops, I had not gone back to the KB article....since it states to delete
the key, my
earlier suggestion to creating this key really makes no sense.

______________________________________

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...

I added the key, but I did not have any values to
put into it. With just adding the key, the problem
was not solved. I still get the "Microsoft Access
Can't Open the Mail Session. Check Your Mail
Application to Make Sure That It's Working Properly."
error message.

Does anyone know what values are supposed to be
under the key?

______________________________________

On Mon, 27 Oct 2003 09:20:53 -0800, Tom Wickerath
<AO***********************@comcast.net> wrote:

Try creating this key as a new entry in your registry.
______________________________________

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...
Yes, I followed all steps in the article, but the registry
entry did not exist on my computer.
______________________________________

On Sat, 25 Oct 2003 13:35:28 -0700, Tom Wickerath
<AO***********************@comcast.net> wrote:

Have you tried the fix that is shown in the KB article you included as a
reference?
______________________________________

"jmr" <jmr1.DelT_his@DelT_his.vianet.ca> wrote in message
news:op**************@news.vianet.ca...

Hi

- I made a macro to send a report as an attachment to an e-mail in
Access 97
- I got the macro to work on WinMe with Netscape as long as the To:
field was not
filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check Your
Mail Application
to Make Sure That It's Working Properly."Q283173
http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.


--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
Nov 12 '05 #7

P: n/a
I've been having problems with SendObject not working with Mozilla Mail. I
scrapped together this code, which is a suitable drop-in replacement for my needs.

This is based on code I found here:
http://nela.mednet.md/others/send_mail.shtml

KC
----------------------------------------------------------------------

Function SendEmail(AddrTo, Optional AddrCc, Optional AddrBcc, _
Optional Subject, Optional Body, Optional ByVal Attachments)
Dim objSession As Object, objMessage As Object
Dim i As Integer, n As Integer, Addr
On Error GoTo error_sendMsg

Set objSession = CreateObject("MSMAPI.MAPISession")
Set objMessage = CreateObject("MSMAPI.MAPIMessages")

objSession.SignOn
objMessage.SessionID = objSession.SessionID
objMessage.Compose
objMessage.MsgIndex = -1

For n = 1 To 3
Select Case n
Case 1: Addr = AddrTo
Case 2: Addr = AddrCc
Case 3: Addr = AddrBcc
End Select

If Not IsMissing(Addr) Then
If Not isBlank(Addr) Then
If Not IsArray(Addr) Then
Addr = Replace(Addr, ";", ",")
Addr = Split(Addr, ",")
End If
For i = 0 To UBound(Addr)
If Not isBlank(Addr(i)) Then
objMessage.recipindex = objMessage.RecipCount
objMessage.RecipAddress = Addr(i)
objMessage.RecipType = n
objMessage.AddressResolveUI = False
End If
Next i
End If
End If
Next n

If Not IsMissing(Subject) Then objMessage.MsgSubject = Nz(Subject, "")
If Not IsMissing(Body) Then objMessage.MsgNoteText = Nz(Body, "")
If Not IsMissing(Attachments) Then
If IsArray(Attachments) Then
For i = 0 To UBound(Attachments)
If Not isBlank(Attachments(i)) Then
objMessage.AttachmentIndex = i
objMessage.AttachmentPathName = Attachments(i)
End If
Next
ElseIf Not IsNull(Attachments) Then
objMessage.AttachmentPathName = Attachments
End If
End If

objMessage.Send True
objSession.SignOff

On Error GoTo 0
SendEmail = True
Exit Function

error_sendMsg:
On Error GoTo 0
SendEmail = False
End Function

Function isBlank(v)
On Error GoTo Problem
isBlank = IsNull(v) Or v = ""
Exit Function
Problem:
isBlank = True
End Function

-------------------------------------------------------

jmr wrote:
Hi

- I made a macro to send a report as an attachment to an e-mail in
Access 97

- I got the macro to work on WinMe with Netscape as long as the To:
field was not filled in.

- I just rebuilt a Dell laptop with WinXP Professional with Outlook
Express. I installed Access and tried the macro, but the error message
below was the result.

- Before rebuilding it, I had tried it with Access2002 and Outlook
Express on WinXP and it worked fine.

Error Message: "Microsoft Access Can't Open the Mail Session. Check
Your Mail Application to Make Sure That It's Working Properly."
Q283173 http://support.microsoft.com/default...b;en-us;283173

- I tried the hyperlink mailto and it works fine on all systems:
cmdEMail.HyperlinkAddress = "mailto: " & Me!txtEmailName

Has anyone else had troubles with SendObject and found a solution?
Ideally, I want to use vba to send out a bunch of e-mails to employees
with their pay stub as an attachment. I can make everything else work
except the send object.


Nov 12 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.