I am creating a report which contains tables at the top and bottom that are always visible. However, between these are 12 tablixes which optionally appear based on the existence of data for them. When they do not exist there is a considerable amount of whitespace in the middle section of the report which makes the report look awful.
I've tried two strategies to fix this:
Set up one rectangle to hold all tablixes. Set all tablixes to have the hidden property set to be true if CountRows() < 1. Leave no gaps in between the tablixes so as to not leave cumulative gaps.
Set up one rectangle per tablix. Set all rectangles and all tablixes to have the hidden property set to be true if CountRows(dataset for tablix) < 1. Leave no gaps in between the rectangles so as to not leave cumulative gaps.
I can think of no other setting to rid the report of gaps for hidden tables.
How about a table with separate rows that contains all your tablixes (tabli?) .
Hide the row based on the tablix's no data condition.
It doesn't help for left to right though since hiding a column leaves space.
So, I noticed that there were warnings about overlapping objects. I went back through and removed overlaps and my report did much better at reducing white space. It's not perfect, but acceptable.
Overlapping objects screw up the whitespace on reports! I don't get any warnings about overlapping objects but I tried adjusting the report to ensure no objects were overlapping and it fixes the whitespacing issues without the need for tables!
Related
I have a number of UI elements like panels, edit fields, buttons, labels etc. so panels contain other panels which contain input fields, editors and so on. Most of the elements are editable and/or resizable which means whenever I change anything, a lot of adjacent UI elements should change their width, height and x/y position on the pane. It works fine with a small number of elements but incredibly slow when the number of elements is thousands.
Is there a fast layout algorithm which can be used in this case? Note that I cannot use any existing layout managers and should come up with my own implementation.
I'd suggest taking a leaf out of the Android playbook and have a larger 'grid' and keep everything sized in modular multiples - this avoids you needing to solve the knapsack problem everytime!
For example, instead of having a button with an width of 80 and a height of 40 you store this as metadata as {2:1} (assuming your layout grid is 40^40 squares).
This way if you have a work panel with space of, say, {2:12} this could be filled with two objects of size {2:6} or maybe 3 of size {2:4}.
It's pretty simple to fit-to-max too as any available space can just be scaled up (say you delete a {1:1} item you can just expand the one next to it to take the space etc - you can of course create your own rules around whether objects can scale in single directions etc.
The other advantage of this approach is that you can easily manage different screen sizes and resolutions too while still keeping the same framework and look and feel.
I have a .rdlc report with grouping (4 levels).
In the last level, I have a pretty complex design of textboxes/images that can't be done with rows/cols. For example, they overlap on some points.
So what I have to do is to put a Rectangle on the cell and then, inside the Rectangle, put all the components.
The problem I have now is that some of these components can be hidden depending on the data, and because of that, sometimes there is a lot of white space inside the report that I don't want.
Is there any way to shrink the Rectangle if it doesn't have any visible data?
Unfortunately, by design Rows and Columns will not shrink below its definition height/width, therefore, a Rectangle can only be as small as its Cell.
However, you could try to make it as small as possible, and rely on the CanGrow property of Textboxes ("Property" window, under "General" tab), as suggested in the link given above.
I am creating sheet with rows of Sale Sums and Columns of each month. Firstly, I am trying to remove this extra whitespace within the boundaries while keeping the squares the same size. I would like the squares of data to take up the entirety of the region. Also, I have tried creating lines to separate each row but adding grid lines creates lines going through the squares.
go to format > borders
select none in columns
select none in rows
I have a report showing one graph, and another separate report showing another graph. I then have a "master" report which combines these two reports as subreports, side by side.
However, I don't seem to be able to easily make them the same size. This means that the master report looks a bit odd, as one subreport will be just a bit smaller than the other.
I can make them roughly the same size just by repeatedly adjusting the heights of the individual subreports until it looks "alright", but this method is never going to make things exact and is also very tedious.
Surely there's a way to make two reports exactly the same size so that they display fine when includes in the master report?
While subreports aren't aware of each other during the render process, if you're dealing with fixed size elements like charts there's a simple way to accomplish this.
First, make sure you have the properties pane enabled.
Then when you click on a chart you can set its height and weight numerically and be exact:
Set the same size of subreports, but instead of using graphical designer, use properties on the right side. In master report you can mainly just set location of subreports, but size of subreport component does not count.
Hard code the dimensions of your reports/graphs/charts in the properties pane. Make sure your background (parent) level is large enough to contain the other elements.
This is no actual single coding problem, rather a problem of the right approach to a complex issue.
So, I have built a rather complex svg visualisation of my XML data using xslt. It looks like this:
(source: erksst.de)
This is just a small sample of the whole data. There are two or three rows. Each row could contain up to 160 yellow boxes.
(The yellow boxes are letter collections, the blue/grey boxes single letters, the lines represent their way of dissemination.)
It works well so far but I want to optimize it:
(1) minimize the number of line crossing
(2) minimize the number of lines crossing a blue/grey box
(3) minimize the lines being too near to another line.
To achieve this there are things to vary:
(a) The broadest row (in the sample it is the third) is fix. It can't be moved. But the other (two) can be moved in the range of the width of the broadest row. I.e. in my example the yellow box of the second row could be moved some 160 pixels to the right.
(b) Furthermore, in the two smaller rows the margin between the yellow boxes could be varied. In my example there is just one per line. But of course there could be more than one yellow box in the two smaller rows.
(c) The order of the yellow boxes within a row could be altered.
So, many possibilites to realize this visualisation.
The problem is the performance time.
I have started with the line crossing problem by using a function which kind of pre-builds the visualisation and calculates the number of crossings.
The variation with the smallest number of crossings is actually built in the output.
The problem is the time it needs. The transformation with just 100 possibilites and my hole XML data took 90 seconds. Doesn't sound like much, but taking into account that 100 variations are just a very small part of all theoritically possible options and that the visualition should at some point in the future build on the fly on server for a user's selection of the data 90 seconds simply is way too much.
I have allready reduced the visualition template for the calculate line crossings functions to all what is necessary leaving asside all captions and so on. That did help, but not as much as expected.
The lines are drawn as follows: First, all boxes are drawn keeping their id from the original data. Then I go back to my data, look where connections are and build the lines.
You could transform your XML into the DOT language (plain TXT format) by XSLT and process it by GraphViz. I solved some similar issue (although not so huge as yours seems to be) this way.