I have the following output which is bound to a SSRS table:
ID Name Value
1 Assets 100
2 Liabilities 200
3 Expenses 300
4 Loans 400
5 TOTAL 1000
For the last row (TOTAL), which is the grand total of the above rows, and also a part of the result, I want to set the border conditionally as follows:
The last row in the report must look something like this:
----------------
TOTAL 1000
================
Appreciate your inputs.
select the text box, go to Text box Properties -> Border -> Outline -> OK. You can go to the header & footer panel & right click to add border over them separately.
Right-click in the header outside any items in the header, and click Header Properties. On the Border tab, add a left, top, and right border with the style you want. If your report doesn't have headers, you can place borders around just the report body, or you can add headers from the Insert tab.
You can make it by clicking on your right tablix and in properties, expand border style and select Solid for Right. You can select left tablix and again, in properties, expand border style and select Solid for Right. You can put both tablixs side-be-side. Then you will have that vertical line you need.
Unfortunately, SSRS does not have a double-dashed option, but you can use conditional formatting on the textbox to control the border.
With your data:
I have a simple table:
For the detail row, I have set the Top and Bottom border style to be expression-based, based on the value of Name
:
Top:
=IIf(Fields!Name.Value = "TOTAL", "Dashed", "None")
Bottom:
=IIf(Fields!Name.Value = "TOTAL", "Double", "None")
This gives (very close to) the desired result:
However, be aware that you might run into a few issues, as identified in this MSDN thread:
Double Line border turn to be single in Reporting Service
I had to make sure the Bottom border was 3pt in width and that there was a table footer row to get it to look correct in Preview. Excel works fine whatever.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With