You have a number of options for formatting text in SSRS. Here is a good article on formatting options for text boxes. The step by step HTML section is below. Thanks SQLchick,
http://www.sqlchick.com/entries/2010/10/31/using-different-formats-within-a-single-textbox-in-ssrs.html
HTML Tags
This option delivers a bit more flexibility, particularly if you have a complex expression in your textbox. Using HTML tags will work if you have a complex expression (i.e.,First, you do need to define Placeholder Properties on the Expression:
Within the Placeholder Properties, change the default Markup type to be “HTML – Interpret HTML tags as styles.” If you forget to change this radio button, then the html tags will be rendered as literal text.
Then within your expression, insert the HTML tags as needed.
Only a subset of HTML tags are supported within SSRS, such as bold, italics, and underline. The MSDN page on Formatting Text and Importing HTML specifies the valid HTML tags you may use within an SSRS textbox. If you use an HTML tag that isn’t supported in SSRS, it will be ignored.
As a sidenote, using HTML tags within a simple expression will work as well:
However, in a real situation, I would reserve using HTML tags to situations when I have a complex expression. With a simple expression, I’d opt to keep the formatting options simpler.
No comments:
Post a Comment