问题描述
大家好,
我正在做一个asp.net应用程序.我想在其中显示记录中的记录.我有四个列Employee,Project,Date,Module.我想制作这样的报告,如果用户选择Employee,则报告应显示明智的雇员,或者如果用户选择项目,则报告应显示明智的项目.我仍然必须根据过滤器制作不同的四个Crystal Reports.但是我希望这是他们的任何GUI控件或功能,如果用户在报表中选择员工列",则报表将根据员工明智地进行转换.项目和其他任何项目都一样.
如果有人有任何想法,解决方案或文章,请给我.
请帮助我.
Hello Every One,
I am making an asp.net application. In which i want to show records in report. I have four columns Employee, Project, Date, Module. I want to make such a report in which if user select Employee then report should show employee wise or if user select project then report should be display project wise. Still i have to make different four Crystal Reports which shows according to filters. But I want that is their any GUI control or Functionality in which if user selects Employee Column in report Then report is convert according to employee wise. same for project and any others.
If anyone have any idea or any solution or any article then give me.
please help me.
推荐答案
PARAMETERS.
在每个UI选择的背后,我都在报告中设置参数.报告上没有任何直接字段.相反,我将参数作为列放置,并将值传递给代码中的值.
因为在Crystal中,除非您有部分内容,否则您不能对列进行排序.
----------------
还有一种方法是通过
Behind every UI selection I was setting parameters in the report. There wasnt any direct field dropped on the report. Instead I placed parameters as columns and passed values to those from my code.
Because in crystal unless you have sections you cant do much about sorting columns.
----------------
Yet another way is to pass an
子句传递
clause to the SQL query based on the users UI selection. This also makes sense and creates the query before hand. So behind every control you have place a sort on that particular field sql.
Hope it gives you some direction.
这篇关于如何根据不同的列明智显示单晶报表.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!