Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / September 2005

Tip: Looking for answers? Try searching our database.

Sending HTML email with Access 2000

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
SAC - 20 Sep 2005 18:28 GMT
I'd like to send html email with access 2000.

I understand how to send regular text using the Outlook library, but how can
I send html in the body?

I saw a referent to a property of .BodyFormat but maybe Acesss 2000 doesn't
support this.

What can I do?

Thanks.
Rick Brandt - 20 Sep 2005 19:25 GMT
> I'd like to send html email with access 2000.
>
[quoted text clipped - 5 lines]
>
> What can I do?

If you are automating Outlook then you just use HTMLbody instead of Body.

Signature

I don't check the Email account attached
to this message.     Send instead to...
RBrandt    at       Hunter      dot      com

SAC - 20 Sep 2005 20:39 GMT
EXCELLENT!!

Thanks.

> > I'd like to send html email with access 2000.
> >
[quoted text clipped - 7 lines]
>
> If you are automating Outlook then you just use HTMLbody instead of Body.
David C. Holley - 20 Sep 2005 20:46 GMT
Set a Reference to the MicroSoft Outlook 11.0 Object Library Then add
the following code...

Dim objOutlook As Outlook.Application
Dim newMail As Outlook.MailItem

Set objOutlook = CreateObject("Outlook.application")
Set newMail = objOutlook.CreateItem(olMailItem)

With newMail
  .BodyFormat = olFormatHTML
  .HTMLBody = "<HTML><H2>The body of this message will appear in
HTML.</H2><BODY>Type the message text here. </BODY></HTML>"
  (other properties)
  .Send
end With

Set newMail = Nothing
Set objOutlook = Nothing

For the rest of the MailItem properties, open Outlook go to the Visual
Basic Editor and look in HELP for the OUTLOOK OBJECT MODEL then objects
- MailItem

> I'd like to send html email with access 2000.
>
[quoted text clipped - 7 lines]
>
> Thanks.
Rick Brandt - 20 Sep 2005 22:58 GMT
> Set a Reference to the MicroSoft Outlook 11.0 Object Library Then add
> the following code...

Or use late binding so you don't need a reference and it works with all
versions of Outlook.

External references should (almost) never be used in an Access app.

Signature

I don't check the Email account attached
to this message.     Send instead to...
RBrandt    at       Hunter      dot      com

David C. Holley - 20 Sep 2005 23:34 GMT
Habits....

>>Set a Reference to the MicroSoft Outlook 11.0 Object Library Then add
>>the following code...
[quoted text clipped - 3 lines]
>
> External references should (almost) never be used in an Access app.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.