获取从C#的数据为Excel 03/07 [英] Getting data from C# to Excel 03/07

查看:219
本文介绍了获取从C#的数据为Excel 03/07的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有实时数据吨,我处理与C#应用程序文件。处理后的数据是$ P $用特定模板psented在Excel

I have files with tons of real time data that I process with an C# application. After processing the data it is presented in Excel using a specific template.

这是用今天的互操作解决。我必须说,我不完全喘息整个互操作的情况。我必须给每个最终用户终端上手动安装互操作功能,不知何故?它是怎样处理的2003/2007版本的组合?

This is solved using Interop today. I must say I don't completely gasp the whole Interop situation. Do I have to manually install the Interop functionality on each end user terminal somehow? How does it handle the mix of 2003/2007 versions?

推荐答案

如果你知道你的Excel文档(和presuming的结构,你不想和Excel文档中各种复杂的宏/功能/等),您可以使用Excel XML格式生成XML。 我不是指OpenXML的,我指的是在2007年之前使用Excel中的XML格式。

If you know the structure of your Excel document (and presuming you don't want and kind of complex macros/ functions/ etc within the Excel document) you can generate XML using the Excel XML format. I'm not referring to OpenXML, I'm referring to the XML format used by Excel prior to 2007.

我介绍如何在这里做到这一点:的 http://www.aaron-powell.com//blog/september-2008/linq-to-xml-to-excel.aspx

I cover how to do it here: http://www.aaron-powell.com//blog/september-2008/linq-to-xml-to-excel.aspx

与互操作的问题在于它是不是真的设计硬核文档的生成。如果你尝试做了很多的文档处理,你可以运行到锁

The problem with Interop is that it isn't really designed to hard core document generation. If you try and do a lot of document processing you can run into locks

这篇关于获取从C#的数据为Excel 03/07的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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