RDLC Report - Repeating vertical lines on all pages - winforms

I am designing an Invoice (Bill) using RDLC, WinForms, C# in Visual Studio 2012. The Invoice could span from 1 to N pages. I am using Tablix to show the Invoice details (line items) in the Report Body. An Invoice may contain 1 to N line items.
As per the design requirement the Tablix Columns need to be separated by Visible Vertical Lines when the report is viewed, printed or exported. These lines need to start at the top near the Tablix Header and run to the end of the page i.e. they cover the Report Body from top to bottom. The Body part of the Invoice looks something like this:
| SNo.| Code | Quantity | Particulars | Rate | Amount |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
I thought of 2 options to do this:
Turn ON the border of the Tablix on all 4 sides.
This does not work because if the records are less, then the lines are only shown half way through the page.
Turn OFF the border of the Tablix on all 4 sides and use the LINE OBJECTs to decorate the Invoice and extend it till the end of the page. This works only on the first page and no Lines are shown on the subsequent pages.
There were other options that I thought of, but did not give me a clean result and was a compromise in other areas.
Please help me as I am completely stuck.

In a VS2005 application (no Tablix) I had to:
set body height so that the sum of header height + body height + footer height + top/bottom margin = PageSize.Height
put one rectangle for every column OVER my table (i.e. 1 rectangle for SNo. column, 1 rectangle for Code column)
set RepeatWith of every rectangle to my table
I think the same solution will work for VS2012, Tablix and Line: try to set Line.RepeatWith to your Tablix.

You can use list for displaying data with a table inside it.
Then have a list height full upto bottom. Draw vertical lines inside list upto bottom.
Then in list group, provide following expression.
ROWNUMBER(nothing)\20.
20 is the number of lines required on one page.

Related

Combining fields in Google Data Studio

I have a CSV file of the form (unimportant columns hidden)
player,game1,game2,game3,game4,game5,game6,game7,game8
Example data:
Alice,0,-10,-30,-60,-30,-50,-10,30
Bob,10,20,30,40,50,60,70,80
Charlie,20,0,20,0,20,0,20,0
Derek,1,2,3,4,5,6,7,8
Emily,-40,-30,-20,-10,10,20,30,40
Francine,1,4,9,16,25,36,49,64
Gina,0,0,0,0,0,0,0,0
Hank,-50,50,-50,50,-50,50,-50,50
Irene,-20,-20,-20,50,50,-20,-20,-20
I am looking for a way to make a Data Studio view where I can see a chart of all the results of a certain player. How would I make a custom field that combines the data from game1 to game8 so I can make a chart of it?
| Name | Scores |
|----------|---------------------------------|
| Alice | [0,-10,-30,-60,-30,-50,-10,30] |
| Bob | [10,20,30,40,50,60,70,80] |
| Charlie | [20,0,20,0,20,0,20,0] |
| Derek | [1,2,3,4,5,6,7,8] |
| Emily | [-40,-30,-20,-10,10,20,30,40] |
| Francine | [1,4,9,16,25,36,49,64] |
| Gina | [0,0,0,0,0,0,0,0] |
| Hank | [-50,50,-50,50,-50,50,-50,50] |
| Irene | [-20,-20,-20,50,50,-20,-20,-20] |
The goal of the resulting chart would be something like this, where game1 is the first point and so on.
If this is not possible, how would I best represent the data so what I am looking for can work in Data Studio? I currently have it implemented in a Google Sheet, but the issue is there's no way to make views, so when someone selects a row it changes for everyone viewing it.
If you have two file games as data sources, I guess that you want to combine them by the name, right?
You can do it with the blending data option. Resource > manage blends I think is the option.
Then you can create a blend data source merging it by the name.
You can add also both score fields, with different labels.
This is some documentation about it: https://support.google.com/datastudio/answer/9061420?hl=en

Grid with grouped headers/columns (super headers)

I would like to achieve something like:
Day 1 | Day 2
--------------------------------------| -------------------------------------
Location 1 | Location 2 | Location 3 | Location 1 | Location 2 | Location 3
---------- | ---------- | ----------- | ---------- | ---------- | -----------
| | | | |
-----------------------------------------------------------------------------
| | | | |
-----------------------------------------------------------------------------
| | | | |
-----------------------------------------------------------------------------
| | | | |
-----------------------------------------------------------------------------
I need to display a list of appointments/events for specific days but grouped by locations.
I want to display days and locations even when there are no events (just empty grid so I can add my own events there).
I'm planning on using DataGrid or ListBox/ListView. Is it a good idea or I should create those headers some other way? Could you point me in the right direction?
This question is just about displaying empty grid(multiple listviews or datagrid with headers generated from list of locations and list of dates):
public IObservableCollection<DateTime> DaysToDisplay { get; set; }
public IObservableCollection<string> LocationsToDisplay { get; set; }
I'm a bit confused by your edit saying:
"This question is just about displaying empty grid (generated from list of locations and list of dates)"
Because that directly contradicts:
"I need to display a list of appointments/events for specific days"
But you keep on editing your question and one of those can't be true.
WPF datagrid is best for editing, if that's what you mean by "add my own events there". Although editing directly in a datagrid introduces a lot of edge cases if you are going to validate.
The datagrid doesn't support grouped headers like that.
All solutions you could adopt come with some limitations.
One would be to make the Days template columns. You then line up your 3 locations inside them in the one template.
One way of building these repeated columns dynamically:
https://gallery.technet.microsoft.com/WPF-Dynamic-XAML-Awkward-41b0689f
Another option is 2 datagrids.
The top one only has headers - these being the Days.
The main datagrid is below that and in the same grid, the locations are columns in that.
This works best if the user can't do things like resize and re-order columns.
Re-sizing can be handled by binding the width of the day columns using a converter adds up the width of the corresponding day columns.
An example:
https://social.msdn.microsoft.com/Forums/vstudio/en-US/1e414159-70f6-4be3-9be5-56e4f3278366/wpf-multicolumn-super-header?forum=wpf

Pulling ill-formatted data in Libre Calc: What Function will work with this?

I am working on a project where I am pulling tables from a Fandom Wikia page and feeding it into a spreadsheet named 'WikiPullSheet'. The data in the wiki tables is irregular in format; sometimes using multiple rows for the same entry.
Here is an example of some rows as described above from the sheet:
Name | Power | Stamina | Agility
Townsman Shield | 2 | 1 | 2
Starter | | |
Broken Shield | 4(+1) | 2(+1) | 2(+1)
Z1 | | |
Heater | 2(+1) | 4(+1) | 2(+1)
Z1 | | |
Wood Elf Shield | 2(+1) | 2(+1) | 4(+1)
Z1 | | |
Shiv | 4 | 4 | 3
Z1 Shop | | |
Deimos* | 26 | 16 | 26
| 34 | 22 | 34
I want the sheet to auto-update from the wikia page but this format will not allow me to reference items as the sheet expands. For instance, if on another sheet I want to have a drop down list of all the names for items in this list, I would be referencing the blank and starter cells even though they are not actually unique items in the table. I have done research on VLOOKUP, COUNTIF, REGEX options, MATCH, and more, but none of these seem to work for the issue I am having.
How would I take this input and either create a formula to reformat it or pull from the sheet as is and use the columns appropriately for a drop-down box containing only the item names from the NAME column?
Desired Output:
I need the data to end up formatted with each row representing a different unique item. Since the information is pulling with rows that contain location of the item in the name column (Z1 for instance), this is proving difficult. I could simply remove the rows that cause problems such as 'Z1' & 'Z1 Shop' in the above example, however this does not help when an item has multiple upgrade paths like in the case of the 'Deimos' row entry.
If you insert a pivot table (there is a icon to do so, select ColumnA first) based on ColumnA (assuming that is where Name is to be found) you should get something like:
It is far from a complete solution (you don't show what the desired output should be) but I thought a sorted list, with each entry unique and the blanks at least out of the way, might have been a start.

How to add a break-out aggregate row group in SSRS

I know virtually nothing about SSRS, so forgive me if I'm using the wrong vocab.
The group I'm working for has a list of volunteer opportunities. Each opportunity has a specified number of volunteers needed. The database keeps track of people who have volunteered, for which opportunity they volunteered, and the status of their volunteering: whether they've just signed up and need to be contacted, whether they're somewhere in the process of becoming a volunteer, whether they are volunteering, or whether they've quit volunteering.
Certain volunteer opportunities (i.e. those requiring contact with children and therefore requiring a background check), have more volunteer states than the rest of the opportunities. For these opportunities there are a total of 14 states, compared to 3 or 4 for the rest.
I need to create a report that displays the counts of people in each state for each opportunity. It's unreasonable for there to be 15 columns (14 + the volunteers needed) for states when most have only three. For children-related opportunities, I want to specify an 'other' column, and have a expansion [+] to the left of the volunteer opportunity name which will expand out all the children-specific states with their associated counts.
The report as it is now looks like this:
My background is in database/query design, so naturally I wrote a query with a joined sub-query for each of the columns. Rather than making an additional new subquery for each of the 'Other' states, I assume there's a way that I can have a single subquery join grouping on the volunteer status, and let SSRS do the rest of the work. (I may be wrong about SSRS's capabilities here.)
My proposed query looks something like this:
SELECT vo.name, vo.volunteers_needed, vm.status, vm.status_count
FROM tbl_volunteer_opportunity vo
JOIN (SELECT volunteer_opp_id, status, COUNT(*) "status_count"
FROM tbl_volunteer_opportunity_member
GROUP BY volunteer_opp_id, status) vm ON vo.volunteer_opp_id = vm.volunteer_op_id
I now need to make a tablix and/or datasource to make columns for the Connected, In Process, No Contact, and an aggregate for Other values, and then do something else for a expansion for each of the Other statuses.
I'm not sure how to do either of those things.
Assuming you have a query that returns data in the following format:
+-------------+--------------------+-------------+-------+
| ProfileName | Status | StatusGroup | Count |
+-------------+--------------------+-------------+-------+
| A | Needed | Needed | 5 |
| A | Connected | Connected | 3 |
| A | In Process | In Process | 5 |
| A | No Contact | No Contact | 2 |
| A | Other status | Other | 3 |
| A | Another status | Other | 6 |
| A | Yet another status | Other | 2 |
+-------------+--------------------+-------------+-------+
You then create a tablix that uses the ProfileName as a row grouping, and the StatusGroup as a column group. The tablix will look like this in the designer:
+-----------------+
| [StatusGroup] |
+-----------------+-----------------+
| [ProfileName] | [Sum(Count)] |
+-----------------+-----------------+
You can then add a totel column on the right, and add an additional level to the column group with interactive expand/collapse functionality (to expand the "Other" StatusGroup into the individual statuses). Using SSRS expressions, you should be able to hide the expand/collapse button on the column headers of the StatusGroups that are not "Other".
Hope this is enough to get you started.

Limit X-Axis AFTER applying grouping/series values

I have a dataset, which has a list of article names, and a user.
eg.
Article | User
Article1 | ABT
Article1 | ABT
Article2 | ABT
Article1 | MLH
Article2 | MLH
Article2 | MLH
and I have a dataset, which is preparing this in a count, so that the data looks like this:
Article | User | Count
Article1 | ABT | 2
Article2 | ABT | 1
Article1 | MLH | 1
Article2 | MLH | 2
So you can see, I'm just counting the views for each article grouped by the user.
I want to present this in a stacked bar chart, so that the Article is the x-axis and the user is the series, so I can see the popularity of a given article and also see the popularity by user for that article.
eg. (can't post images)
Example Stacked Bar Chart
This works fine, and I have this already, but I want to restrict the actual amount of Articles displayed. I will end up having over 100 articles to display, so i'd like to restrict to top 10-20 articles, but in the same stacked format, so I can't just "TOP N" the dataset, as it could lose series data for a given article.
eg.
Article | User | Count
Article1 | ABT | 100
Article2 | ABT | 98
Article1 | MLH | 10
Article2 | MLH | 2
Putting a "TOP 2" on this would lose series data for the MLH visits to each article.
Is there a way to restrict the X-Axis, after it is prepared for rendering for the chart? Or other solution i've completely missed.
Add a filter to the Category Group (Article):
Expression: =Count(Fields!ArticleName.Value)
Operator: TOP N
Value : 10
returns top 10 for that category after all grouping is applied.

Resources