![]() |
Problem with Saving format of the Excel
Hi All
I am working on ASP.NET application using C#.I have a requirement of genrating an Excel file 0programmatically. For this i tried in two ways. One is , using FileSystem object. Another is , using Excel COM object , Microsoft Office 9.0 object library. 1). using FileSystemObject it was showing the Excel file type as 'Text(Tab Deleimted')' in the SaveAs Dialog box when i am opening the Excel sheet. 2). using Microsoft Office 9.0 object library, that was showing the Excel file type as 'Microsoft Excel Workbook' in the SaveAs Dialog box when i am opening the Excel sheet My problem is, i have to genrate the Excel file using FileSystemObject, which saves the Excel file in the format 'Microsoft Excel Workbook'. So , How to accomplish this ??? Any Ideas?? Thanks in prior Naveen. |
Problem with Saving format of the Excel
I suggest posting .dotnet.framework.aspnet or a similar group.
The FSO cannot create an Excel file in its native binary format. (Well, unless you know how to write a binary file out in your head that would be a valid Excel file...) Server-side automatiion of Office objects is strongly ill-advised by Microsoft. Response.ContentType = "application/vnd.ms-excel" That was always good in classic ASP for basics. As far as the user getting prompted to download, that's a client-side option that the user has set. Ray at work "Naveen" wrote in message ... Hi All I am working on ASP.NET application using C#.I have a requirement of genrating an Excel file 0programmatically. For this i tried in two ways. One is , using FileSystem object. Another is , using Excel COM object , Microsoft Office 9.0 object library. 1). using FileSystemObject it was showing the Excel file type as 'Text(Tab Deleimted')' in the SaveAs Dialog box when i am opening the Excel sheet. 2). using Microsoft Office 9.0 object library, that was showing the Excel file type as 'Microsoft Excel Workbook' in the SaveAs Dialog box when i am opening the Excel sheet My problem is, i have to genrate the Excel file using FileSystemObject, which saves the Excel file in the format 'Microsoft Excel Workbook'. So , How to accomplish this ??? Any Ideas?? Thanks in prior Naveen. |
Problem with Saving format of the Excel
Hi Ray Thanx For u Reply
When User clicks on the button the cxcel sheet was automatically genarated that's why i am using FileSystem object. Another is , using Excel COM object , Microsoft Office 9.0 object library. if u don't mind pls give me an example using the FileStream object how to save excel file in the format of 'Microsoft Excel Workbook' bye naveen |
All times are GMT +1. The time now is 12:19 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com