For Programmers: Free Programming Magazines  


Home > Archive > ASP > February 2006 > file does not begin with %PDF - BinaryWrite









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author file does not begin with %PDF - BinaryWrite
TrailBlazer

2006-02-27, 6:56 pm

Hi - Been struggling over this issue for a long while. We store PDF's
in our SQL Server database. And I do a BinaryWrite to display the PDF.
It works for me without issue, on FireFox, IE, and Opera! But we are
receiving feedback that some users are receiving the file does not
begin with %PDF message.

ExecString = "spwEcoTrackUser " & Session("EcoUserID") & ",'coupon',"
& ID
set dbConn = Server.CreateObject("ADODB.Command")
dbConn.ActiveConnection = conn
dbConn.CommandText = ExecString
dbConn.Execute

' writes out the PDF
Response.ContentType = rs("CouponContentType")
Response.BinaryWrite rs("CouponData")

I have seen several posts about this issue, but no true solution. Can
anyone help?

THANKS!!!!

Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com