?
Solved

Change the color of a string.

Posted on 2006-06-06
4
Medium Priority
?
228 Views
Last Modified: 2010-04-07
This is probably going to be the easiest 500 points anyone has ever earned, but it is worth it to me. I simply want to be able to change the color of a string. I am currently using vbscript with Outlook code behind the forms. when I am sending out my Administrative tasks via email, I want to programatticly format the output to whatever color I want. Is there a function where I can input a string and output the same string in a color of my choosing. I hope that I am making myself clear. An example would be:

***********************************************************************
FIRST NAME                    LAST NAME                     MIDDLE NAME                  
***********************************************************************

MIKE                          SUTTER                       DAVID                        
JAKE                           LONG                          PETER
CINDY                         MARS                         JACKSON
PLUTO                        NASH                          GILBERT
DARYL                        HUDSON                      RONALD
REGIS                         HYDE                          THAYER

HYPOTHETICALLY,  I would like to change the color of the second row to green or som arbitrary color. Alternatively, I would also like to bold the last row. Can this be done in vbscript.  
0
Comment
Question by:BLACK THANOS
  • 2
4 Comments
 
LVL 54

Expert Comment

by:Ryan Chong
ID: 16848366
try make your email content as in HTML format? You can do it using some email components to do that.

References:
http://www.freevbcode.com/ShowCode.Asp?ID=109
http://www.aspfaq.com/show.asp?id=2119
0
 
LVL 6

Expert Comment

by:junglerover77
ID: 16848421
I think you can just build your string like this:

***********************************************************************
FIRST NAME                    LAST NAME                     MIDDLE NAME                  
***********************************************************************

MIKE                          SUTTER                       DAVID                        
<font color="Green">JAKE                           LONG                          PETER</font>
CINDY                         MARS                         JACKSON
PLUTO                        NASH                          GILBERT
DARYL                        HUDSON                      RONALD
<font style="font-weight:bold">REGIS                         HYDE                          THAYER</font>

Hope it works.

Regards,
Jungle
0
 

Author Comment

by:BLACK THANOS
ID: 16862593
all,
 is there any other way to accomplish adding color to my email other than html? As I am unfamiliar with the html technology, are there any html for dummies books anyone can recommend?
0
 
LVL 54

Accepted Solution

by:
Ryan Chong earned 2000 total points
ID: 16862672
If you want your email content to be more interactive/ colorful, you need to have a HTML body in your email.

>>are there any html for dummies books anyone can recommend?
try have a look at:
http://www.w3schools.com/html/default.asp
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

862 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