摘要
水晶报表是具有强大的报表设计功能的专业报表设计工具,能帮助设计人员快速创建具有专业外观的报表。通过研究推模式的工作原理,提出以数据集作为报表数据源,再采用推模式将数据注入数据集的方法,实现了在水晶报表中插入图片的功能。数据注入过程利用数据集支持BLOB字段的特点,从介质中获取图片内容,以字节数组形式存入数据集。这种插入图片的方法减小了水晶报表和数据源的耦合程度,适用于数据来源分散、复杂的场合,或数据获取后需要做进一步处理的场合。
Crystal Reports is a professional report design tool with powerful design capability.The designers can create professional-looking reports quickly with it.By studying the push mode,a method to use dataset as the data source of report,and then inject data into data source by push mode is proposed to achieve the purpose of inserting images into Crystal Reports.The data injection process depends on the characteristics of supportting BOLB field in dataset to get the picture content from the medium and store it in a dataset in the byte array form.To insert pictures by this way reduces the coupling between Crystal Reports and data source,is applied to the occasions that data source is scattered and complex,or the occasion that the data needs for further processing after gained.
出处
《现代电子技术》
2012年第16期73-74,78,共3页
Modern Electronics Technique
基金
重庆市高等教育教学改革研究重点项目:煤矿安全网络监控实训教学研究与实践(09-2-129)
关键词
水晶报表
推模式
插入图片
数据集
Crystal Reports; push mode; picture insertion; dataset;