开发者

Export to Excel tool for asp.net

开发者 https://www.devze.com 2023-03-17 17:44 出处:网络
Is there any tool that can export a dynam开发者_高级运维ically generated html to excel in c sharp?see Create Excel (.XLS and .XLSX) file from C#why do u want to write functionality that already exists

Is there any tool that can export a dynam开发者_高级运维ically generated html to excel in c sharp?


see Create Excel (.XLS and .XLSX) file from C#


why do u want to write functionality that already exists. mean excel has it, u can import any web page (just to note excel uses IE engine to render tags). here are steps how it can be achieved.

Open excel; go to Data Tab; click From Web;

New Web Query child window opens.

write into Address Bar and go to the web page u wan to import.

after page loads into the window click import button

that's all.

(i assumed u are using ms office 2007, if diff version, diff steps)

just one more note. ms office uses IE rendering engine, so not all tags are supported, so if it looks ugly, do not blame me ;)


I'm not sure how you want to export html to Excel. In Excel we are talking about rows and columns while html is a document. You would probably want to export html to Word or pdf.

In any case, for creating Excel files in C# I've used the following 2 libraries: http://www.codeproject.com/KB/office/biffcsharp.aspx and http://code.google.com/p/excellibrary/

0

精彩评论

暂无评论...
验证码 换一张
取 消