direct export of a crystal report

Discussion in 'ASP .Net' started by Fh, Nov 30, 2005.

  1. Fh

    Fh Guest

    Hello,
    I'm using the following code to send the content of a report directly in a
    aspx page.

    this code is working fine,
    but the pb is that it doesn't fill the page with the document.
    it displays automatically the 'open or save' popup...
    I wish to open it directly in the IE window without asking anything?
    how can I do so?

    Thanks for your help

    ----------------code---------------------
    docReport.ExportOptions.ExportFormatType =
    ExportFormatType.WordForWindows;
    MemoryStream m_stream = new MemoryStream();
    m_stream =
    (MemoryStream)docReport.ExportToStream(
    CrystalDecisions.Shared.ExportFormatType.WordForWindows);
    Response.Clear();
    Response.AddHeader("content-disposition",
    "attachment;filename=FileName.doc");
    Response.Charset = "";
    Response.Cache.SetCacheability(HttpCacheability.NoCache);
    Response.ContentType = "application/vnd.word";
    Response.BinaryWrite(m_stream.ToArray());
    Response.End();
    Fh, Nov 30, 2005
    #1
    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. Benny

    export crystal report file

    Benny, Nov 6, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    414
    Benny
    Nov 6, 2003
  2. =?Utf-8?B?c3VpY2lkYWx0ZW5kZW5jaWVz?=

    Export PDF from Crystal Report .NET using ASP.NET

    =?Utf-8?B?c3VpY2lkYWx0ZW5kZW5jaWVz?=, Feb 5, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    3,837
    =?Utf-8?B?c3VpY2lkYWx0ZW5kZW5jaWVz?=
    Feb 5, 2004
  3. fhranck

    Direct export of crystal report file

    fhranck, Nov 29, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    424
    fhranck
    Nov 29, 2005
  4. =?Utf-8?B?VGFuaw==?=
    Replies:
    1
    Views:
    6,133
    srinivasgajula.mca
    Apr 27, 2010
  5. Comfort
    Replies:
    0
    Views:
    546
    Comfort
    Oct 18, 2004
Loading...

Share This Page