Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

How to set html default for new messages when started remotely ?

Posted on 2002-03-12
10
169 Views
Last Modified: 2010-04-08
I'm using SendObject within VBA to send an email.

I have been advised that to have an html formatted email I only have to have an html tagged string for the body of the email.

I have been into options within Outlook and set the mail format to html.

but when I use the SendObject action, an outlook new message window pops up set as plain text.

(when I start a new email within outlook, the new message window pops up formatted for html.)

The problem only occours when starting a new message remotely.

Any ideas how to force html formatting ?
0
Comment
Question by:perrybond
  • 3
  • 3
  • 3
  • +1
10 Comments
 

Expert Comment

by:m-coon
ID: 6856302
This may not be what you are looking for but in Outlook you have a choice of the type of formatting whenever you are writing a new message. On the tool bar, there is a dropdown menu that allows you to choose from HTML, Rich Text, or Plain Text... Unless this is too dificult to do, just choose HTML each time you begin a letter.
0
 

Author Comment

by:perrybond
ID: 6856705
No, I am aware of that, It is an email sent directly from MSaccess using visual basic, that uses Outlook.
i have asked the question in the MSaccess area and checked that that end is correct.
The html option on the pull-down allows you to write data which has the html tags added. My text already has the html tags on, these are displayed insread of being used
0
 
LVL 8

Expert Comment

by:starl
ID: 6857185
perrybond...I've skimmed the access question and since I'm not proficient in access and my vba skills are moderate, I ask this: Are you trying to paste html code on an email in hopes that it will become an actual html message? If so, that is not the way outlook works. You can create an html message elsewhere (say frontpage) and cut & paste that (not the code, but the design) and send an html email in that way, but doing <b>HI</b> in outlook will not send a bolded HI.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 
LVL 9

Accepted Solution

by:
rjcpjc earned 200 total points
ID: 6857268
You can programmatically set the HTMLBody property to an html string.

objMailItem.HTMLBody = "<B>HI</B>"

Feel free to post your code and I can provide more specific suggestions.
0
 
LVL 8

Expert Comment

by:starl
ID: 6857494
<bows to Queen rjcpjc>

So a script could be written to take html text and convert it to script = htmltext to create an html message...
0
 
LVL 9

Expert Comment

by:rjcpjc
ID: 6857510
Yes.  What I've done in the past is to convert an HTML file to a txt file of just HTML code.  Then use the Scripting library and open a textstream object.  Then get the contents of the text stream object and set the HTMLBody property equal to that string.
0
 
LVL 8

Expert Comment

by:starl
ID: 6857543
now that would be a handy function.. I've seen quite a few ppl frustrated that html emails don't become html emails - now what I mean.
0
 
LVL 9

Expert Comment

by:rjcpjc
ID: 6857599
Yep.  I might have some sample code around here somewhere. I looked for another poster a while back and couldn't find it.  I'll have to look again.
0
 

Author Comment

by:perrybond
ID: 6858360
Thanks , I used the .htmlbody property and a new world has opened up for me
0
 

Author Comment

by:perrybond
ID: 6858374
For the full story and all the code see this question

http://www.experts-exchange.com/jsp/qManageQuestion.jsp?ta=msaccess&qid=20275364

The first bit has the general code

Later is mentioned the .htmlbody as opposed to an attachment

then how to set the reference

rjcpjc - I think you got some easy points, but I'd hate to get a reputation for being tight !
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Following basic email etiquette rules will help you write a professional email and achieve a good, lasting impression with your contacts.
This article lists the top 5 free OST to PST Converter Tools. These tools save a lot of time for users when they want to convert OST to PST after their exchange server is no longer available or some other critical issue with exchange server or impor…
Many of my clients call in with monstrous Gmail overloading issues with Outlook. A quick tip is to turn off the All Mail and Important folders from synching. Here is a quick video I made to show you how to turn off these and other folders in Gmail s…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question