Loading ...
Sorry, an error occurred while loading the content.

Re: Embedding PDF in an HTML

Expand Messages
  • dennis_joel_david
    At least, I know how it can be done using ASP or ASP.NET. This C# code snippet outputs a raw byte stream to the browser window, using ASP.NET. private void
    Message 1 of 3 , Aug 4, 2003
    • 0 Attachment
      At least, I know how it can be done using ASP or ASP.NET.

      This C# code snippet outputs a raw byte stream to the browser
      window, using ASP.NET.

      private void Page_Load ( object sender, EventArgs args )
      {
      Response.Clear();
      Response.ClearContent();
      Response.ContentType = "application/pdf";
      byte [] buffer = SomeFunctionToRetrieveTheByteArray();
      Response.BinaryWrite(buffer);
      Response.Flush();
      buffer = null;
      }



      --- In XSL-FO@yahoogroups.com, "vvelu" <vvelu@y...> wrote:
      > Folks:
      >
      > Embedding a PDF in an HTML page (rather than launching it in a
      > separate window) is possible by using the <embed> tag. However,
      this
      > needs a PDF file to be stored on the server side and the URL must
      > point to that file. Is there a way to avoid storing a file? As
      the
      > FOP creates the PDF, can it be streamed directly to the embedded
      to
      > the HTML page in which it is embedded.
      >
      > Your help will be greatly appreciated.
      >
      > Thanks
      > Sam Velu
    Your message has been successfully submitted and would be delivered to recipients shortly.