June 2, 2010 at 9:43 pm
Hi
i have a table in my report.I want to display the name field as BOLD if the Amount field is 0.ELse the name field must be italic.
i am using SSRS 2005
How is this done..
thanks in advance...!!
June 2, 2010 at 10:39 pm
Almost every property in SSRS can be set through an expression as well as directly entering a value. Right-click the Name text-box, and select text-box properties. Select the "Font" tab. Right beside the "Bold" checkbox is a button (fx) - click this, and in the dialog box that appears you can enter an expression for calculating the FontWeight. Note that the result needs to be a string.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
June 11, 2010 at 8:29 am
Hi,
All you need to is select the relevent cell in your table and then in the properties window (press f4 if you can't see it)
under the font heading you will see fontstyle (you will also see fontweight and will need a separate expression for this), you need to click on the drop down list next to them and select expression from the list. You will need to type something like
=iif(fields!myamountfield.value = 0,"italic","Normal")
You will need an expression for fontweight as well
=iif(fields!myamountfield.value = 0,"bold","Normal")
Thanks
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply