将DataGrid插入到水晶报表VS2010中的特定部分 [英] Inserting DataGrid to a particular section in crystal report VS2010

查看:67
本文介绍了将DataGrid插入到水晶报表VS2010中的特定部分的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的数据库由5行组成,每行由学生注册主题。

以下是我的数据库设计:

My database consist of 5 rows where each row consist of students register for subjects.
Following is my database design :

Name		|USN	|SubCode  |Test1  |Test2  |Sum	
StudentName 	 001	 Sub001	   27 	    35     62 
StudentName 	 001	 Sub002	   28 	    30     58
StudentName 	 001	 Sub003	   35 	    35     70
StudentName 	 001	 Sub004	   30 	    35     65
StudentName 	 001	 Sub005	   33 	    27     50   



从上表中,由于studentname和USN很常见,我只需要一个这样的实例

数据,我希望Subcode,Test1,Test2和Sum列以数据网格视图格式显示在水晶报表的特定

部分。这可能吗?


From the above table, as studentname and USN is common, i just need an instance of those
data and I want Subcode, Test1, Test2 and Sum column to be displayed in a particular
section of crystal report in a datagrid view format. Is this possible?

推荐答案

您可以创建数据集(使用VS中的数据集组件)。将该数据集添加到水晶报告中。在报表的设计模式中,将所述数据拖放到任何您想要的位置。



现在您只需要在代码中创建报表实例并传递它包含数据的真实数据集。



您可以轻松找到详细信息。
You can create a dataset (using dataset component in VS). Add that dataset to crystal report. In design mode for the report, drag and drop said data wherever you want.

Now all you have to do is create the instance of the report in code and pass it real dataset with your data.

You can easily find the details googling.


这篇关于将DataGrid插入到水晶报表VS2010中的特定部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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