在运行时报表中设置空间 [英] set space in report on runtime

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

问题描述

我正在创建rdlc类型的Microsoft报告并设计一个列表,我希望在运行时设置报告页边距,并根据Windows应用程序中用户的值添加列和列之间的空间.很多,我想打印5 * 4尺寸的标签.每页打印9或12个

在此先感谢您

I am creating a microsoft report of rdlc type and design a list and i want that on runtime,I set report margins and add columns and space between columns on the basis of user''s value in windows application.I tried a lot and i want to print 5*4 size labels.and 9 or 12 per page

Thanks in advance

推荐答案

我过去所做的就是添加一个
参数
@StartAtLabel

您需要确保确认用户不能告诉它以高于每页标签总数的标签开头.

然后,您将获得一个包含列表的报告,该报告上设置了2列.

在sql部分中,将UNION ALL添加到select语句,该语句将为您告诉它丢失的每个标签选择空白记录(或"####"),然后如果文本框值=="## ##",则您不会显示这些值.
然后,该标签将从该位置开始,因为报表将用空格填充其余值,并且不会在这些位置打印.

困难的部分是设计要根据标签大小工作的报告.
通常,创建新的报告PER标签大小会容易得多.

我想如果您愿意,也可以通过参数设置边距和列.
What I have done in the past is add a parameter that is

@StartAtLabel

You need to make sure you validate that a user cannot tell it to start at a label higher than the total of labels per page.

Then you have a report that contains a list, 2 columns set on the report.

In the sql part you add a UNION ALL to a select statement that will select blank records (or "####") for each one of the labels you tell it to miss, and then if the textbox value == "####" then you dont show the values.
This will then have the label start at the position because the report will fill in the rest of the values with blanks, and will not print in those places.

The hard part is designing the report to work based on label size.
Its usually a lot easier to create a new report PER label size.

I suppose if you wanted to you could set the margins and columns via parameters as well.


这篇关于在运行时报表中设置空间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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