ASP to Excel

Discussion in 'ASP General' started by Ben Moen, Dec 31, 2003.

  1. Ben Moen

    Ben Moen Guest

    I'm not sure which group is most appropriate for this
    question; I'll also post this in office solutions
    development. I am running into problems with something
    that seems to be a popular requirement - porting data from
    an asp page to an Excel workbook to allow users to
    manipulate data. I have a few different methods working,
    but also with some issues. I want to know if these are
    technical limitations, or if there is another direction to
    take such as web query...

    I have successfully used the "Response.ContentType
    = "application/vnd.ms-excel" in ASP to stream everything
    in the page as an Excel document. However, when I use
    this, simple SUM() formulas do not work in the resulting
    Excel worksheet. The worksheet does not recognize results
    from my dataset as true number types.

    In response to a previous post, I tried using another
    method - constructing, and manipulating a worksheet object
    using ActiveX. This allows the user to play with the
    resulting worksheet, however, they would be required to
    change their default IE settings. This is a corporate
    intranet app, and requiring our entire user base to tweak
    their browser settings is going to be unreasonable.

    I am trying to stay away from writing out distinct Excel
    files on the server for performance, and security
    concerns. As I understand it, web query will generate a
    physical file to download. Can web query instead stream
    content to a browser? Any other suggestions?

    THANKS,

    Ben
    Ben Moen, Dec 31, 2003
    #1
    1. Advertising

  2. using the code from http://www.greggriffiths.org/webdev/both/excel/ you
    should be able to get a working sample where the XL file is created on
    the server side and then a link is returned to the uesr allowing them to
    open the file in their browser.

    Ben Moen wrote:

    > I'm not sure which group is most appropriate for this
    > question; I'll also post this in office solutions
    > development. I am running into problems with something
    > that seems to be a popular requirement - porting data from
    > an asp page to an Excel workbook to allow users to
    > manipulate data. I have a few different methods working,
    > but also with some issues. I want to know if these are
    > technical limitations, or if there is another direction to
    > take such as web query...
    >
    > I have successfully used the "Response.ContentType
    > = "application/vnd.ms-excel" in ASP to stream everything
    > in the page as an Excel document. However, when I use
    > this, simple SUM() formulas do not work in the resulting
    > Excel worksheet. The worksheet does not recognize results
    > from my dataset as true number types.
    >
    > In response to a previous post, I tried using another
    > method - constructing, and manipulating a worksheet object
    > using ActiveX. This allows the user to play with the
    > resulting worksheet, however, they would be required to
    > change their default IE settings. This is a corporate
    > intranet app, and requiring our entire user base to tweak
    > their browser settings is going to be unreasonable.
    >
    > I am trying to stay away from writing out distinct Excel
    > files on the server for performance, and security
    > concerns. As I understand it, web query will generate a
    > physical file to download. Can web query instead stream
    > content to a browser? Any other suggestions?
    >
    > THANKS,
    >
    > Ben
    Greg Griffiths, Jan 1, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Anonieko
    Replies:
    2
    Views:
    7,295
    JackStraw73
    Feb 12, 2008
  2. Robbe Morris [C# MVP]

    asp.net extracting excel charts from an Excel file

    Robbe Morris [C# MVP], Dec 15, 2006, in forum: ASP .Net
    Replies:
    0
    Views:
    468
    Robbe Morris [C# MVP]
    Dec 15, 2006
  3. =?Utf-8?B?c2hhc2hhbmsga3Vsa2Fybmk=?=

    Problem with Excel reports ::::Excel 2003 Migration To Excel 2007

    =?Utf-8?B?c2hhc2hhbmsga3Vsa2Fybmk=?=, Oct 5, 2007, in forum: ASP .Net
    Replies:
    15
    Views:
    1,486
    =?Utf-8?B?c2hhc2hhbmsga3Vsa2Fybmk=?=
    Oct 24, 2007
  4. Grey
    Replies:
    4
    Views:
    1,947
    Mark Rae [MVP]
    Oct 17, 2007
  5. fniles
    Replies:
    6
    Views:
    636
    Karl E. Peterson
    Apr 27, 2009
Loading...

Share This Page