Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing Font Size

Status
Not open for further replies.

bmares

Technical User
Jan 12, 2006
5
US
I am currently using Crystal 8.5 and we will be upgrading to Crystal 10.0 in the next month, so I need help that will work with both versions.

I have a formula that is {field name} + "HEALTH"

In this formula field is there anyway to take the word "HEALTH" and have the "H" font size 12 and the "EALTH" have the font size of 10?

Thank You!


 
You could use HTML tags, but I think the easiest method would be to add three items to a text box, where you have the ability to format each element separately:

1-{table.field}
2-a formula: "H"
3-a formula: "EALTH"

When you drop them in the text box, you can highlight the element and format it as you wish.

If in fact, "HEALTH" is just an example of a field result, use formulas like:

{table.field}[1]

...and:

mid({table.field},2)

-LB
 
If you're using a Text Box, you don't need a formula for the Health portion, drop your field in and afterwards just type Health, adjust the H to size 12, and the ealth to size 10.

You can also use conditionals within the formula for the Size of the font to check for certain conditions and alter the font size of formulas in their entirety, but the above should suffice as the requirements are described.

-k
 
Right, SV, I wasn't thinking there...

-LB
 
The word 'HEALTH' is a string located in a formula field.

if {PROVID}="113572" then
"HEALTH" &" "& "has allowed payment."
else
"No payment made."

When the formula field is insterted into the report it is font size 12. I need the word HEALTH to be all uppercase with the H size 12 and EALTH size 10.

Is this possible in a formula field?

Thank You!
 
Use a formula like:

if {PROVID}="113572" then
"<font size = 4>H</font size>"+ "<font size = 2>EALTH</font size>" &" "& "has allowed payment." else
"No payment made."

Then go to format field->paragraph->text interpretation->HTML Text. You'll have to play with the font numbers until they meet your needs, as the numbers do not correspond to the usual font sizes.

-LB
 
Or to use the actaul font sizing, create a text box of the H formatted at 12, ealth at 10, then drop in a formula containing:

if {PROVID}="113572" then
" has allowed payment."

Right click the text box and select format text->X2 next to suppress and place:

{PROVID} <> "113572"

Then create another text box of

if {PROVID} <> "113572" then
"No payment made."

and set it's suppression formula to:

{PROVID} = "113572"

Overlay one atop the other.

Now each will fire according to the ruloes, and you can use the Windows based font rendering

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top