Link to home
Start Free TrialLog in
Avatar of Kaporch
Kaporch

asked on

Underlining one word in a text phrase in Crystal Reports 11

I have a text phase:

You can make a difference

that's has the "You" underlined and in italics, the rest in just italics. I tried to create the field using 2 separate text fields on one line, and it didn't appear correctly in the editor.  (Too much space)

I see something in a book about using HTML and RTF interpretation in a Crystal report.  I tried to format the field like this:

<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1252">
<META NAME="Generator" CONTENT="Microsoft Word 97">
</HEAD>
<BODY>
<I><U><Font Face="Comic Sans MS">You</U> can made a difference</FONT></I>
</BODY>
<HTML>

using Text Interpretation, and I'm getting a message that the remaining text does not appear to be part of the formula.  Can anybody see what I'm doing wrong?
Avatar of frodoman
frodoman
Flag of United States of America image

The html interpretation is very limited.  Create this formula instead:

<I><U>You</U> can make a difference</I>

If you want to specify the font you're better off formatting the field normally to select the font you want.

frodoman
Oops - You'll actually need to enclose that formula in quotes:

'<I><U>You</U> can make a difference</I>'


frodoman
Avatar of Kaporch
Kaporch

ASKER

That formula is not interpreting the HTML correctly but seeing it as part of the text and printing out:

<I><U>You</U> can make a difference</I>
ASKER CERTIFIED SOLUTION
Avatar of frodoman
frodoman
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
As you probably have gathered from my last response, Crystal doesn't interpret html tags unless you specifically format the field to do so.

Also, you can embed <font> tags in your html and it will work.  I just don't advise doing so because Crystal won't recognize that font as being used so if you end up deploying the report you can run into problems if the font doesn't exist on the target machine.  It's safer to rt-click and format the formula with the font you want to be sure Crystal recognizes that font is in use.

frodoman