I'd drop the idea of creating an MDB.
But on the excel side, you don't have to using office automation to "create"
an excel spreadsheet. Excel know how to parse HTML tables, so you can
create a spreadsheet that way.
Response.Clear()
Response.ContentType = "application/vnd.ms-excel"
Response.AddHeader("Content-Disposition", "filename=" + "calculations.xls")
Response.write("<table><tr><th>Data</th><td>2</td></tr></table>")
Response.End
If you are using VS.NET make sure to remove everything from the .aspx file
except for the <% @Page ...%> directive.
Don't change the name of the page from .aspx! That is handled by the
Content-Disposition header
If you provide a link to this page, the user will be prompted to download
the .xls file or open it in Excel.
If you need actual formulas and stuff in the spreadsheet, you'll have to do
some experimenting. Don't know if that can be done.
"A.M" <IH*******@sapm123.com> wrote in message
news:Oj*************@TK2MSFTNGP10.phx.gbl...
Hi,
Using ASP.NET/VB.NET and SQL Server backend,
I need to return calculation results to user as an Access MDB file or
Excel XLS sheet.
What would be the best way to create a MDB or XLS file inside a .NET
program?
Thanks,
Ali