在循环中设置Crystal Report参数 [英] Set Crystal Report Parameter in Loop

查看:57
本文介绍了在循环中设置Crystal Report参数的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

hiii,

我想知道如何在C#中设置Crystal Report的参数.而我想在Loop中设置此参数.

当我使用时:

hiii,

i want to know how to set paramater of Crystal Report in C# . and this parameter i want to set in Loop.

when i use :

cr.SetParameterValue(0, ds.Tables[0].Rows[0][1].ToString());
cr.SetParameterValue(1, company_name);
cr.SetParameterValue(2, database_name);


这将只显示一个记录,但我想显示更多记录.



在此先感谢.
Mitesh


this will display only one record but i want to display more record .



Thanks in Advance.
Mitesh

推荐答案

如果要打印多个相同时间的值,则将数据表设置为source.然后在详细部分中打印这些字段.
水晶报表不支持动态参数.在Crystal报表中添加参数后,必须通过该参数.
在您的情况下,您想使用循环进行设置.您的数据表包含许多记录,因此您必须将其设置为源并在详细部分中进行打印.
否则,请给我您要打印的确切定义.所以我可以帮助您..
If You want to print multiple time same value then set datatable to source. And then print those field in detail section.
Crystal report not support dynamically parameter. Once you add parameter in crystal report that parameter you have to pass.
In your case you want to set it using loop. your datatable contain many record so you have to set it as source and print it in detail section.
Other wise give me your exact definition what you want to print. So i can help you..


这篇关于在循环中设置Crystal Report参数的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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