.net mvc HTML导出EXCEL
NPOI可以在没装OFFICE的情况下操作EXCEL,WORD等,也不用在程序中引用微软的office组件。另外我加了在MVC中把HTMLTABLE导出EXCEL的方法。
调用代码如下:
usingNPOI;
publicFileResultGetFile(stringhtml)
{
html=Server.UrlDecode(html);
ExportFileresult=newExportFile(html);
result.AlertErrmsg="HTML不正确:"+html;
returnresult.GetResult(
下载地址
用户评论