Downloading to Excel.

Results 1 to 2 of 2

Thread: Downloading to Excel.

  1. #1
    Join Date
    Dec 1969

    Default Downloading to Excel.

    I&#039;ve written an asp page that will download the contents of a table to a csv file using this code: <BR> Response.ContentType="application/csv" <BR> Response.AddHeader "Content-Disposition", "filename=test.csv;" <BR> Response.write "ID," <BR> Response.write "Test," <BR> Do Until RS.EOF <BR> Response.write(RS("ID") & ",") <BR> Response.write(RS("Test") & ",") <BR> RS.MoveNext <BR> Loop <BR>Is there any way I can download three tables to one excel spreadsheet, each table to a different worksheet? <BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Downloading to Excel.

    with your current code, you are not downloading anything to an excel spreadsheet... you are downloading the values to a text file.... Excel is configured to read a .csv, but a .csv is not a spreadsheet, it cannot hold formating or multiple sheets...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts