从ASP.NET生成Word文档的最佳解决方案是什么? [英] What is best solution to generate Word document from ASP.NET?

查看:128
本文介绍了从ASP.NET生成Word文档的最佳解决方案是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从我的ASP.NET应用程序生成一个Word文档.当前,我们显示一个议程列表",它是议程信息和所有项目/主题.此页面需要具有用文字打开的功能.议程页面不是静态的,它是从SQL Server中提取的议程项目的动态列表.

I would like to generate a word document from my ASP.NET application. Currently we show an "Agenda List" which is the agenda information and all items/subjects. This page needs to have the ability to open in word. The agenda page is not static, it's a dynamic list of agenda items pulled from SQL Server.

对最佳解决方案有何建议?我正在寻找一种快速的解决方案,而OpenXML似乎有点耗时.我愿意购买第三方工具.

Any suggestions on the best solution? I'm looking for a quick solution and OpenXML seems to be a bit too time consuming. I'm open to purchasing third party tools.

谢谢!

推荐答案

使用Office OpenXML SDK.对于更高版本的Office(2007及更高版本),这是标准.还有其他答案中提到的其他方法,但是OpenXML将为您提供对输出的最大控制.

Use the Office OpenXML SDK. For later versions of Office (2007 and above), this is the standard. There are other ways as mentioned in other answers, but OpenXML will give you the greatest level of control over the output.

以下是一些文档,可以帮助您入门: http://msdn.microsoft.com/en-us/office/bb265236.aspx

Here is some documentation to get you started: http://msdn.microsoft.com/en-us/office/bb265236.aspx

这篇关于从ASP.NET生成Word文档的最佳解决方案是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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