zoukankan
html css js c++ java
[BizTalk]让BizTalk消息中携带附件.
Use System.Xml.XmlDocument as the part type for the message, this is treated
as a generic stream of data. Then you can use a stream of data for this
part.
实现这样一个功能:
1.访问SQL Reporting Service得到一个报表的数据
2.将报表数(stream)赋给BizTalk中的一个消息中。
使用
System.Xml.XmlDocume数据类型.
代码如下:
public
static
void
CreateReportPart(XLANGMessage msg,
int
partIndex,
string
reportName)
{
System.IO.Stream reportStream
=
ReportServicesProxy.GetReport(reportName);
ReportStreamFactory factory
=
new
ReportStreamFactory(reportStream);
msg[partIndex].LoadFrom(factory);
}
public
class
ReportStreamFactory : IStreamFactory
{
System.IO.Stream _stream;
public
ReportStreamFactory(System.IO.Stream stream)
{_stream
=
stream;}
public
System.IO.Stream CreateStream()
{
return
_stream;}
public
void
Dispose()
{_stream.Close();}
}
通过类似这样的方案,就可以将附件添加到消息中了
查看全文
相关阅读:
python(4):Python应用场景
python(3):python的优缺点
MySQL(17):用户登录实例
MySQL(16):参数化、封装
MySQL(15):与python交互的增删改查
MySQL(14):与python交互的类型
MySQL(13):索引
c++ --程序编译
c++ -- 顺序容器操作
c++ --string操作
原文地址:https://www.cnblogs.com/xuzhong/p/236283.html
最新文章
crontab命令详解
<利用Python进行数据分析> Note 4
<利用Python进行数据分析> Note 3- pandas, series, reshape, reindex, lambda, apply, value_counts
<利用Python进行数据分析> Note 2
<利用Python进行数据分析> Note 1
What next? ---class, def, pickle, dictionary, make a address book
cPickle and pickle
Python dictionary---one key and multi-value
使用Git命令把本地项目上传到github上托管
JS 时间转换为时间戳
热门文章
Docker部署之Django开发
django+Echarts实现数据可视化
git上传本地文件到gitlab
django1.11如何实时访问mysql数据库
django+Python数据库利用Echarts实现网页动态数据显示
操作系统常见面试题总结
初步对深度学习&&机器学习&&模式识别的理解
python(7):标识符、关键字、输出
python(6):输入、变量类型
python(5):中文支持
Copyright © 2011-2022 走看看