断开与数据源的连接 [英] Disconnecting from data source

查看:87
本文介绍了断开与数据源的连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

我有与XML数据合并的报告模板(.rpt文件)(ADO.NET DataSet)。问题是,当报告与数据合并然后删除XML文件时,如果我加载报告(例如将其导出为PDF),则API想要访问数据源(在我的情况下是删除的) XML文件)。有很多报告,我需要删除数据文件以节省磁盘空间。有没有办法让API不再访问数据源?我希望报表实例与任何数据源断开连接。

I have report templates (.rpt files) that I merge with XML data (ADO.NET DataSets). The problem is that when report is merged with data and then the XML file is deleted, then if I load the report againg (e.g. to export it ti PDF), the API wants to access the data source (which in my case is the deleted XML file). There is lot of reports and I need to delete the data files to save space on disk. Is there a way how to make the API not to access data source again? I want the report instance to be disconnected from any data source.

非常感谢

eXavier

推荐答案

如果您只是想节省磁盘空间,请不要删除数据集本身,只删除xml文件,这只使用内存
if you are just trying to save disk space, don't delete the dataset itself, just the xml file, this only uses memory


这篇关于断开与数据源的连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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