Group is created to the right of Parent

断了今生、忘了曾经 提交于 2020-01-03 05:09:09

问题


I cannot figure out for the life of me how to add a sub group to a parent group but to have that sub group sit below the parent group row. Right now if I right click the parent group and add a child group..it adds a child group but to the RIGHT of the first parent group's cell in the report.

Anyone?? How the heck do you get child groups to sit below the parent row?

For example my report will have a parent group that holds a CarType For each Car Type group, it has several related car names

------------------------------------------------
Honda
Field1   3   4   54  534
Field2   5   3   44  455
------------------------------------------------
Accord
Field1   53  3   43  222
Field2   5  22   24  423

Pilot
Field1   4  3    5   221
Field2   5  27   24  423

..... rest of the car types for honda


------------------------------------------------
Toyota
Field1   3   4   54  534
Field2   5   3   44  455
------------------------------------------------
Camry
Field1   53  3   43  222
Field2   5  22   24  423

xxxx
Field1   4  3    5   221
Field2   5  27   24  423

..... rest of the car types for camry

and so on. So we don't want the children to be indented (I'm not sure if this is now not going to be stepped or what..that's what I'm having trouble with cause every example out there on the net shows you how to do a stepped report but shows the the child group indented in a little which we don't want for x business reasons.

I can't get this parent/child set of rows to look like this in the report. I want nested (parent/child) but child should be starting flush left, not indented in relation to the parent when viewing the data.

Here is an example in another report and you can see the groups stacked:

another example in another report


回答1:


There's probably more than one way to do this, but I'll explain this way to keep it easy to follow.

  1. Start with a table, and add your child group to the first column in the details row.
  2. Right-click that cell with your child group, point to Add Group, and then click Parent Group in the Row Group section.
  3. In the Group By drop-down list, select the parent group and select the Add group header check box, and click OK. Another column gets added to the left of your detail group and the Row Groups pane now shows the parent group and child group. A new row appears between the table header and the child row (details row)
  4. Delete the new column.
  5. Add the parent field to the first column in the row above the details row.



回答2:


Quick, albeit non-intutive, fix for adding a new Parent Group after the tablix has been created:

  1. Add the Group in the groups section.

  2. A new column to the left will appear and probably mess your beatiful layout. Don't leave that new section just yet.

  3. Right-click and insert a new Row.

  4. Mark that new row by writing something on it (i.e. "This is Parent 01")

  5. Right-click the newly (and undesirable) "left grouping column". Delete it and be careful to just delete the column, NOT the associated group level.

  6. Voilà! Now you have a new Parent Group and a place where to put things in it, like a new group title, aggregates or whatever you fancy.

Hope it helps! If, not drop a line.



来源:https://stackoverflow.com/questions/10933547/group-is-created-to-the-right-of-parent

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!