Print Page | Close Window

Bold font and non bold font in one formula?

Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2020
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=17938
Printed Date: 07 May 2024 at 7:35am


Topic: Bold font and non bold font in one formula?
Posted By: swatts
Subject: Bold font and non bold font in one formula?
Date Posted: 06 Nov 2012 at 8:26am
I have a formula that has an if statement but I want the result be like this:

You chose A: Thank you for your choice.

Is this possible?




Replies:
Posted By: DBlank
Date Posted: 06 Nov 2012 at 8:34am
you can either use two formulas placed into one text box and contrrol each formula formatting seperatly
or you can use the HTML text interpretation and write your formula to include the tags, something like:
if condition A then "<b>You choose A:<b> Thank you for your choice" else
if condition B then "<b>You choose B:<b> We do not thank you for your choice" else
 


Posted By: swatts
Date Posted: 06 Nov 2012 at 8:45am
Ahh! Awesome! Worked like a charm!


Posted By: swatts
Date Posted: 06 Nov 2012 at 8:54am
Well, I guess I can't have my cake and eat it too.

It threw off my replace.

I had a replace({thisfield},"&",Chr(13)) because of a multiple selection field with & separating the answers.


Instead of this:
How many colors do you see?
Red
Green
Blue
Yellow

I get:
How many colors do you see?RedGreenBlueYellow


Posted By: DBlank
Date Posted: 06 Nov 2012 at 9:32am
"<b>how many colors do you see:<b> <br>" + replace({thisfield},"&","<br>")


Posted By: swatts
Date Posted: 06 Nov 2012 at 9:40am
You are the master, thank you!



Print Page | Close Window