locked
Excel on Web RRS feed

  • Question

  • User1150582658 posted

    I'm creating a site that has multiple forms that are using ASP.net 1.1 I believe.  They are then storing this data into a SQL database.  I am then creating a seperate page that lets the user select the report they want and hit a generate button.  When this button is hit I'm opening an excel form in VBScript populating it with data from the SQL database and then I want to save it and send it to the user.  This code all resides on the server.  We don't want any client code, this system is meant to be self contained. 

     When I try to save the excel sheet using ObjWorksheet.SaveAs("c:/...) it throws an error.  Saying it could not be found.  It could be one of three things.  Does not exist, is open and I can't remember the last one.  I know it works on the server side because I can use localhost and it works just fine.  Does anyone know a way around this?  I am grateful for any insight into this problem. I'm using Excel 2007.  Thanks.

     

    Friday, September 26, 2008 11:24 PM

All replies

  • User1150582658 posted

    Here is the actual error message:

     

    Microsoft Office Excel cannot access the file 'c:\Spreadsheets'. There are several possible reasons:

    • The file name or path does not exist.
    • The file is being used by another program.
    • The workbook you are trying to save has the same name as a currently open workbook.

    Monday, September 29, 2008 1:39 PM
  • User1150582658 posted

    I have an idea, does anyone know if this works?  Can I have the client open up a form or template from the server and then edit the spreadsheet with data from my sql server, because then it will be client side excel and I avoid the server side fiasco.  Will this work with ASP.net coding?

    Monday, September 29, 2008 2:26 PM