473,320 Members | 1,872 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

SendObject Woes

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
7 5880
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
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
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
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
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
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
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 thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Bret Shortall | last post by:
Using the SENDOBJECT action command in a Macro works fine if you hard code in their email address. SENDOBJECT TO bret@emailaddress.com SUBJECT This is the Subject line...
0
by: jmr | last post by:
Hi I checked out the other messages first, but I only found one for SendObjects, but it was in German, so... - I made a macro to send a report as an attachment to an e-mail in Access 97 -...
1
by: Alfred | last post by:
Hi I am using access 2002 1.0 I want to email a word or html file using the docmd.sendobject The document must be send as a attachment. 2.0 Second I would like to tell the Docmd.Sendobject to...
8
by: Andy Kasotia | last post by:
Warning message in Outlook 2003 while using SendObject. When i try to use sendobject to send an email, a warning massage pops up, saying that "Outlook is trying to send an email.......if this is...
9
by: bobdydd | last post by:
Hullo Everybody I am trying to send a email from WITHIN Access 2000 with a report attached that is generated WITHIN Access in the normal way, but all the help examples I have seen uses an...
1
by: Dave Holmes | last post by:
please can anybody help with sendobject command it works on some computers and not others. (Same App) regardless of OS I get message The command or Action isn't available now I am trying to...
3
by: Fred Zuckerman | last post by:
Hello All, I had written a quick email procedure for a client that uses DoCmd.SendObject. However they have the SR-1 version of Access 2K. They do not have the SP-3 upgrade. The procedure does...
2
by: Andy_Khosravi | last post by:
I posted this question about two days ago, but for some reason it never actually got put up. I couldn't' find it with searches, so I am re-posting it now. I apologize if this is a double post. ...
0
by: (PeteCresswell) | last post by:
Another thread got me going on SendObject. Works like a champ for emailing somebody a .SNP of a report as in: DoCmd.SendObject acSendReport, "rptMaturities", "Snapshot Format", "pCresswell", ,...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.