本文介绍了.NET 2008的前N个报告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我用Crystal XI创建了前N个晶振报告.创建了一个组,该组将用于前N个摘要.然后创建了一个参数,并在前N个组排序专家中为其分配了参数.
问题是,当我更改.rpt文件中的参数值时,报表可以正常工作.但是,当我从.net 2008中传递参数时,它将采用参数的默认值.
有什么问题吗?
有人可以建议吗?
Shailesh
这是我用来设置参数的代码:
I have created a Top N crystal reports with Crystal XI. Created a group which will be used for Top N summary. Then I created a parameter which I assigned it in Top N group sort expert.
The problem is The report works perfectly when I change parameter value in .rpt file. But when I pass parameters from .net 2008 it takes default value of the parameter.
What could be wrong?
Can anyone suggest?
Shailesh
Here is the code I use to set the paramaters:
Dim crParameterFieldDefinitions As CrystalDecisions.CrystalReports.Engine.ParameterFieldDefinitions
Dim crParameterFieldDefinition As CrystalDecisions.CrystalReports.Engine.ParameterFieldDefinition
Dim crParameterValues As New CrystalDecisions.Shared.ParameterValues
Dim crParameterDiscreteValue As New CrystalDecisions.Shared.ParameterDiscreteValue
crParameterDiscreteValue.Value = Value
crParameterFieldDefinitions = objReport.DataDefinition.ParameterFields
crParameterFieldDefinition = crParameterFieldDefinitions.Item("BottomN")
crParameterValues = crParameterFieldDefinition.CurrentValues
crParameterValues.Clear()
crParameterValues.Add(crParameterDiscreteValue)
crParameterFieldDefinition.ApplyCurrentValues(crParameterValues)
推荐答案
这篇关于.NET 2008的前N个报告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!