Bolding Certain Part of Text in Telerik Reporting

1 Answer 137 Views
Expressions
Nick
Top achievements
Rank 1
Nick asked on 05 Jul 2023, 04:00 PM

I would like to bold one of the If Then Statements, when i convert my text box to an html text box i get an error.  Here is my code.

 

= 'Each of the undersigned (herein referred to individually and collectively as “Owner”) hereby guarantees, represents and warrants to ENTERPRISE Crude Oil, LLC (“ECO”), its successors and assigns, that each Owner is the legal owner of the Owner’s respective interest, in the proportions hereinafter stated, in all Oil (as defined herein) produced and saved from the ' + If(Count(Fields.[Property #]) > 1, "See Exhibit A", Fields.[Property Name])+  ' located in the County of ' + If(Count(Fields.[Owner Name]) > 1, "See Exhibit A", Fields.[County Name] + ', State of ' + Fields.CityState) + ', described as follows (the “Lands”):'

1 Answer, 1 is accepted

Sort by
0
Momchil
Telerik team
answered on 10 Jul 2023, 11:01 AM

Hi Nick,

Thank you for sharing your expression.

It appears that the <strong> element that is added after bolding the If Then statement is misinterpreted as an expression. In such cases, it often helps to convert the value of the HtmlTextbox to use Embedded Expressions. The following appears correct on my end.

Each of the undersigned (herein referred to individually and collectively as “Owner”) hereby guarantees, represents and warrants to ENTERPRISE Crude Oil, LLC (“ECO”), its successors and assigns, that each Owner is the legal owner of the Owner’s respective interest, in the proportions hereinafter stated, in all Oil (as defined herein) produced and saved from the <strong>{If(Count(Fields.[Property #]) > 1, "See Exhibit A", Fields.[Property Name])}</strong> located in the County of {If(Count(Fields.[Owner Name]) > 1, "See Exhibit A", Fields.[County Name] + ', State of ' + Fields.CityState)} , described as follows (the “Lands”):

Make sure to set the above expression directly as the HtmlTextbox's Value or through the Html view. Otherwise, the bold text will not appear.

I hope this helps you get the desired result.

Best Regards,
Momchil
Progress Telerik

Stay tuned by visiting our roadmap and feedback portal pages, enjoy a smooth take-off with our Getting Started resources, or visit the free self-paced technical training at https://learn.telerik.com/.
Tags
Expressions
Asked by
Nick
Top achievements
Rank 1
Answers by
Momchil
Telerik team
Share this question
or