在Crystal Reports中显示树状行视图 [英] Displaying a Tree like view of rows in crystal reports

查看:72
本文介绍了在Crystal Reports中显示树状行视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨哥们
有一个名为产品"的数据库表,其中存储了产品规格和属性.每个产品都有0,1或多个子产品.如果没有子产品,则该产品为子产品,应在树状的Crystal报表中显示在父行的底部(通过树状报表,我指的是一些子产品的缩进).如果您询问如何区分子产品和父产品,我将通过一个名为id_index_product的特殊列来回答,该列针对每个产品均显示其父产品(父ID),并且该列是否为Null,即父产品的父产品必须显示在报告的顶部.
我的想法是这样的:


Hi buddies
there is a Database table Named "Product" which stores Product Specifications and attributes. each Product has 0,1 or many child product . if it has no child product, the product is child product and should be displayed at the bottom of the parent row in a tree-like Crystal report ( by tree-like report I mean, some indentations for child products). if you ask how child and parent products are distinguished, I would answer, by a special column named id_index_product which for every product shows its parent ( parent id) and if the column would be Null, that is the Parent of parents Product which has to be shown at the top of the report.
What I have in mind is something like this :


Product1        (Parent of parents)
  Product2 (child of P1)
  Product3
    Product4  (child of P3)
  Product5
    Product6
      Product7
Product8        (Parent of parents)
 Product9
 Product10



我曾经使用过分组和分层分组,但是我认为我使用它们的方式不正确.所以没有成功.

我想知道您是否指导我如何完成它.
我使用VS 2008(C#)-和Crystal Reports Basic for VS 2008



I''ve used grouping and Hierarchical grouping but I think I used them incorrectly. so no success is achieved.

I wonder if you guide me how to get it done.
I use VS 2008 (C#)- and Crystal Reports Basic for VS 2008

推荐答案

子报表

C#Crystal Reports-子报告 [ C#Crystal Reports-按需子报表 [ ^ ]
Subreports

C# Crystal Reports - sub reports[^]
C# Crystal Reports - on demand sub reports[^]


这篇关于在Crystal Reports中显示树状行视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆