J
Jim Bunton
Is it possible to automate sending an email based on a report to a list of
emails addresses in a table column?
emails addresses in a table column?
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
429: ActiveX component can't create object
Jim Bunton said:Tom -
Thanks for the additional info.
Ironically! I'm having an issue with the 'OutLook' approach
*** code ***
Dim myObject As Object
Dim myItem As Object
Dim strFullPath As String
Dim strFileName As String
Dim strAttachPath As Variant
Dim intAttachments As Integer
Set myObject = CreateObject("Outlook.Application")
*** End Code ***
gives error:-
429: ActiveX component can't create object
Posted here and in public.Outlook > no responses!
So
I decided that I would have a go with OutLookExpress & SendObject
[I'm happy to create the messageTxt string in code rather than my original
idea to use a report]
this worked fine but then I hit a snag! See posting "SendObject" at 15:56 in
this group
Jim
ossible cause of problems - I have been using Casper Xp by futureTom Wickerath said:Hi Jim,
429: ActiveX component can't create object
Do you have Outlook installed on the computer that you are trying to run
this code from? If you do, then I suspect that you have some other issue
going on, like perhaps Outlook is not properly registered. Do you have a
different PC available, which has Outlook installed, that you can test
your
code on?
See if this information helps:
You receive run-time error 429 when you automate Office applications
http://support.microsoft.com/?id=828550
INFO: Troubleshooting Error 429 When Automating Office Applications
http://support.microsoft.com/?id=244264
Tom Wickerath
Microsoft Access MVP
http://www.access.qbuilt.com/html/expert_contributors.html
http://www.access.qbuilt.com/html/search.html
__________________________________________
Jim Bunton said:Tom -
Thanks for the additional info.
Ironically! I'm having an issue with the 'OutLook' approach
*** code ***
Dim myObject As Object
Dim myItem As Object
Dim strFullPath As String
Dim strFileName As String
Dim strAttachPath As Variant
Dim intAttachments As Integer
Set myObject = CreateObject("Outlook.Application")
*** End Code ***
gives error:-
429: ActiveX component can't create object
Posted here and in public.Outlook > no responses!
So
I decided that I would have a go with OutLookExpress & SendObject
[I'm happy to create the messageTxt string in code rather than my
original
idea to use a report]
this worked fine but then I hit a snag! See posting "SendObject" at 15:56
in
this group
Jim
Jim Bunton said:Hi Tom,
Thanks again! - both outlook and word failed on createobject.
Word worked after Run . . . winword /RegServer
Run . . . Outlook /regserver failed
Solution - Repair Office 2000
Set MyWordObject = CreateObject("outlook.Application") NOW WORKS
[Noteossible cause of problems - I have been using Casper Xp by future
systems to substantially restructure my discs in order to partiton the 'as
delivered' system disc C:]
HOWEVER
this code below using sendobject still fails to run as anticipated
(correctly?!)
** code **
. . . . .
For nRecepiants = 1 To 3
'will assign new values to sendTo
DoCmd.SendObject objectType, objectName, outputformat, sendTo,
sendCc, sendBcc, sendSubject, sendMessage, editmessage, templateFileName
Next 'nRecepiants
MsgBox "Emails sent", vbOKOnly, "End"
** End Code **
First time through the loop an email is placed in Outlook's outbox
second and third time nothing happens!
Run the function again - nothing happens (no email generated no error
generated)
Close the Access application - same result (email generated on first pass
through the loop but subsequently bo emails generated)
Jim
Tom Wickerath said:Hi Jim,
429: ActiveX component can't create object
Do you have Outlook installed on the computer that you are trying to run
this code from? If you do, then I suspect that you have some other issue
going on, like perhaps Outlook is not properly registered. Do you have a
different PC available, which has Outlook installed, that you can test
your
code on?
See if this information helps:
You receive run-time error 429 when you automate Office applications
http://support.microsoft.com/?id=828550
INFO: Troubleshooting Error 429 When Automating Office Applications
http://support.microsoft.com/?id=244264
Tom Wickerath
Microsoft Access MVP
http://www.access.qbuilt.com/html/expert_contributors.html
http://www.access.qbuilt.com/html/search.html
__________________________________________
Jim Bunton said:Tom -
Thanks for the additional info.
Ironically! I'm having an issue with the 'OutLook' approach
*** code ***
Dim myObject As Object
Dim myItem As Object
Dim strFullPath As String
Dim strFileName As String
Dim strAttachPath As Variant
Dim intAttachments As Integer
Set myObject = CreateObject("Outlook.Application")
*** End Code ***
gives error:-
429: ActiveX component can't create object
Posted here and in public.Outlook > no responses!
So
I decided that I would have a go with OutLookExpress & SendObject
[I'm happy to create the messageTxt string in code rather than my
original
idea to use a report]
this worked fine but then I hit a snag! See posting "SendObject" at
15:56
in
this group
Jim
Jim Bunton said:The problem with SendObject:
Only sends once In Access 2000
Resolution:- Install Service Pack 3 for Office
Details at
http://support.microsoft.com/kb/260819/en-us
Jim Bunton said:Hi Tom,
Thanks again! - both outlook and word failed on createobject.
Word worked after Run . . . winword /RegServer
Run . . . Outlook /regserver failed
Solution - Repair Office 2000
Set MyWordObject = CreateObject("outlook.Application") NOW WORKS
[Noteossible cause of problems - I have been using Casper Xp by future
systems to substantially restructure my discs in order to partiton the 'as
delivered' system disc C:]
HOWEVER
this code below using sendobject still fails to run as anticipated
(correctly?!)
** code **
. . . . .
For nRecepiants = 1 To 3
'will assign new values to sendTo
DoCmd.SendObject objectType, objectName, outputformat, sendTo,
sendCc, sendBcc, sendSubject, sendMessage, editmessage, templateFileName
Next 'nRecepiants
MsgBox "Emails sent", vbOKOnly, "End"
** End Code **
First time through the loop an email is placed in Outlook's outbox
second and third time nothing happens!
Run the function again - nothing happens (no email generated no error
generated)
Close the Access application - same result (email generated on first pass
through the loop but subsequently bo emails generated)
Jim
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.