Worksheet to HTML

Arch4ngel

Well-known member
Joined
Mar 22, 2004
Messages
940
Location
Montreal, QC
ASSEMBLY : Microsoft Excel 10.0 Object Library

I have a excel file that I receive through a HttpPostedFile and I save to a server folder (dont matter... all the right permission are set)

What I want to do is to save each worksheet into an HTML format like : Worksheet1.html, worksheet2.html, worksheet3.html... etc.. etc..

I tried the SaveAs method from the Worksheet Excel object but it dont work quite well.

Somebody have some experience on that kind of problem ?
 
Problem solved.
C#:
public[/color][/size][size=2] [/size][size=2][color=#0000ff]void[/color][/size][size=2] SaveAsHtml()[/size]
[size=2]{[/size]
[size=2][color=#0000ff]object[/color][/size][size=2] n = [/size][size=2][color=#0000ff]null[/color][/size][size=2];[/size]
[size=2]m_ws.SaveAs(@"C:\Inetpub\wwwroot\Locations\doc\PAGE1.HTML", Excel.XlFileFormat.xlHtml, n, n, n, n, n, n, n, n);[/size]
[size=2]}
 
Back
Top