I'm starting to use SSRS and would like to start my project on a clean manner and easy to change in a future the style of the report.
So I'm declaring several parameters for each layout properties (font-family, fonz-size, color, border-style, border-width,....) and would like to know if it's possible to do "merge some" :
instead of doing this for each property :
This would be more efficient and easy to set. But Visual Studio (2015 version) doesn't allow me to do it.
In CSS we can do "padding : 10px 5px 2px 4px" or "padding-left: 10px; padding-right: 5px...." (other possiblities but wanted to show here only the corresponding).
Thanks for your help.
Yes you can - you just need to put a comma between each.
Copy and paste this into the top level padding property:
=Parameters!ReportParameter1.Value, 19pt, =Parameters!ReportParameter1.Value, =Parameters!ReportParameter1.Value
and then expand that property - you will see that padding right has been set.
Unfortunately when you select all the entities (i.e rows within a taxlib) that have different properties the Padding options for Left, Right, Top and Bottom will disappear. In order to do this, you will need to copy the formatting to a notepad. Then clear all formatting from the existing select all and then simply copy and paste. It's very daunting, but I have found that there is no other way sadly.
I found the solution !!
For example, I want to set the border color for property Left,Right,Top,Bottom at once :
Declare a parameter TableBody_BorderColor_LRTB.
In "General" check "Allow multiple values"
In "Default Values", select "Specific values
Click to "Add" 4 times for the 4 values
By our custom convention, the first value will refer to Left (L is at the first position of LRTB), the 4th value will refer to Bottom
Then select the body of the tablix, and in the BorderColor property write :
Black; =Parameters!TableBody_BorderColor_LRTB.Value(0); =Parameters!TableBody_BorderColor_LRTB.Value(1); =Parameters!TableBody_BorderColor_LRTB.Value(2); =Parameters!TableBody_BorderColor_LRTB.Value(3)
The "Black" is for the default Color.
And then we select the first value Value(0) that is assigned to Left, etc...
Related
I am developing a multi-grouped report. Base on the level of a group, I am to set the bottom border width to 2pt else 1pt. I only know how to set the default for all groups. I have googled and tried various expressions but unable to get around the requirement.
An example of what I want to achieve is shown in the image below
I would imagine you could evaluate the scope on a group and set a row(s) bottom border accordingly.
If you right-click a row I assume you could apply the following in an expression:
<For the Border.BorderWidth.Bottom property of the detail or row group>
=IIF(Level("MyGroup")=0,"1pt","2pt")
The answer by Ross Bush seems to be correct. Though I would use Choose as it gives more options should you need more width.
I've used 10pt and 20pt so the difference is easily visible for this example.
I have created a Directional indicator (Green up arrow and Red down arrow) in my SSRS report, referring to the value of the column next to it. This all works ok:
However, I really want the indicator and the value to be in the same cell, like Excel can:
A Google found the following article , where the last post suggest it is possible using the following syntax:
=Format(Fields!Column1.Value, "Format") + " " + "Indicator"
I assume "Indicator" refers to the name I gave to my Direction indicator, but I can't get it to work..
I have read that by using border formatting I can get my two cells to look like one, but I would ideally like it all to be in one.
Any thoughts appreciated!
Mark
I would do this by placing a Rectangle inside of the cell and place your indicator along with another text box inside the rectangle. The downside to this is (depending on how you align the items in the rectangle) the formatting may cause split cells in excel exports.
Ross's method will work and there are alternatives..
The article you referenced was a text indicator not an image (from what I could tell).
You could do something similar by simply adding a a placeholder in the cell (right-click inside the cell and click "create placeholder"). You can then set the font and colour independently from the rest of the cell.
You could use a common font such as wingdings to get arrows and then the value and color properties would be expressions to show the correct 'character' (arrow) and the correct colour.
This is very similar to the post on Formatting multiple fields at once in RDL, but there are still issues with setting properties like Size.Width and Font.FontSize when the underlying data is different between selected cells.
Here's the accepted answer:
Select all the controls in the designer and press F4 for properties. Change the background color
But if falls short when there is a property that is made up of several child properties. Here's an example using font and size, each of which are comprised of several properties.
This is what it looks like when a single field is selected or when multiple fields are selected that all have the same value:
But if I highlight several cells that have different font sizes, or widths, I lose the ability to edit them all simultaneously. For example if I wanted to make consistent column widths across an entire report.
Here's what the properties look like when multiple fields are selected and any of them have a different value:
It's not ideal, but in the case of the size property, I can enter the shorthand value which includes both width and height separated by a comma and it will apply that change to all the selected cells.
But for some reason, in the Font section, I can't even do that.
Other things I've tried:
Using the Formatting Toolbar - which seems to be always greyed out for SSRS:
Using the Formatting Menu Item - which doesn't expose the FontSize property:
Using the Context Menu to enter the Properties Form, which is disabled:
They will be greyed out if they are not identical in all fields selected. This can depend on a related formatting field being different.
One workaround is to create an internal text parameter:
With default value of the value you want to use for the property:
Then set the property for each cell that should have the same formatting to this parameter individually:
Repeat this for each of the relevant child properties, you will then be able to change formatting across the report by changing the parameters.
In Spotfire:
Is it possible to show target value reference line for each bar in a bar chart.
A way around that i am doing now is using combination chart. Refer screenshot.
The problem here is that now i can not define a color by property to color bars using rules.
I don't believe you can do it automatically without scripting but here is an example of how to do it by hand.
Right click on your bar chart and go to the Lines & Curves section:
Here you can see I've added 4 lines based on percentage of the data.
You can do this or add lines of set values using the Add button in the top right and selecting Horizontal Line.
Notice I've added the line name as the description of the percentage it is, hovering over will show an actual value so it may better to do this if it isn't clear what the value represents.
This is what it produces:
To make it better match your question I've added 2 more employees and coloured by employee instead, I've also set fixed targets for each person rather than percentages and renamed them to make sure it is clear which line applies to which person in case the colour isn't enough.
Using the Settings -> Appearance section back in the first picture change the colour of the lines to match the fields they represent.
Like I said at the start you should be able to create a script to do this for you but that is another question.
I have a report with a table in it. And each table cell has borders around it.
The problem I'm experiencing is that if I hide the textbox in any of the cells, the borders also disappear.
I want the textbox to hide but still show the borders.
The textbox in question shows the visibility toggle icons (+/-) so I can't use an iif statement to change the textbox's value to be an empty string when I don't want to see anything in it.
You can place the textbox inside a rectangle.
***So , I was having this same issue:* **
The Problem:
I assume that you placed a border around your text box and decided to place the hide and toggle element to your text box. or your Rows are not stepped down. Two solutions, I think the first solution is what you are looking for:
Solution 1:
I Noticed that SRSS reporting also has this grouping feature by rows. So to hide the text in the textbox without losing borders is to create a step-down feature within the grouping. So basically you can assign hide text box property without disturbing the rows above the textbox. This may be a better solution.
Solution 2:
You must instead place the border attribute to your text box and place the hide and toggle function on the individual groups. So for you, you have to remove the hide + toggle feature on the textbox. Right click the group element in your "rows" or "columns" and assign your drilldown hide + toggle feature on the group elements. In other words: "group properties" not "text box properties"
I hope this re-solve your issue.
I ran into the same issue. I solved it by changing the text color to white (or whatever the background color of the textbox is). I was doing this inside a table, and couldn't find a way to insert a textbox inside of a rectangle as stated in the other answer...
I had similar problem and used similar approach like #Anony Mous, but instead of changing text color to background color I used expression to change text value =IIF(InScope("RowGroup") = "True", Fields!Textboxvalue.Value, "") - and it works as expected.
Problem with background color change is that, if user unintendely select the text and makes it active, it become visible.
Just select the Textbox in question, run F4 (to access to the properties chart at the right side of VS or SQL), select the HideDuplicates dropdown and Select the Data Set that you are using :)