dbTalk Databases Forums  

Reporting Services PDF fails in Netscape

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Reporting Services PDF fails in Netscape in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
jt
 
Posts: n/a

Default Reporting Services PDF fails in Netscape - 09-22-2004 , 05:56 AM






(This is not strictly an OLAP issue, but I wanted to put it into a managed
group.)

I'm working on a ASP.NET/Reporting Services web app in which the user fills
in information, saves it to a DB, and retrieves a PDF by pressing a button.
It's basically a mailmerge using RS.
I'm using the RS web service and code to create and deliver the pdf.
The app delivers the PDF without a problem to IE. And the PDF works fine in
IE and Netscape when the user retrieves the report Using MS Report Manager.
But the PDF blows up with the user calls the report out of the app using
Netscape. It looks like this:

%PDF-1.3% 1 0 obj [/PDF /Text /ImageB /ImageC /ImageI] endobj 3 0 obj <<
/Type /Page /Parent 2 0 R /MediaBox [0 0 612.000071 792.000092] /Contents 4 0
R /Resources << /ProcSet 1 0 R /XObject << >> /Font << /F5 5 0 R /F6 6 0 R
/F7 7 0 R >> >> >> endobj 4 0 obj << /Length 1941 /Filter /FlateDecode >>
stream x……

and so on.

Here are the relevant parts of the code that builds and delivers the PDF:


Dim deviceInfo As String = "<DeviceInfo>" + _
"<Columns>1</Columns>" + _
"<Dpix>300</Dpix>" + _
"<Dpiy>300</Dpiy>" + _
"<EndPage>0</EndPage>" + _
"<PageWidth>8.5in</PageWidth>" + _
"<StartPage>0</StartPage>" + _
"</DeviceInfo>"

....
dim mimeType As String = "application/pdf"
Dim sh As localhost.SessionHeader = New localhost.SessionHeader

...

report = rs.Render(reportPath, format, historyId, deviceInfo, parameters,
credentials, _
showHideToggle, encoding, mimeType, reportHistoryParameters, warnings,
streamIDs)

sh.SessionId = rs.SessionHeaderValue.SessionId
Response.Clear()

' Set the HTTP headers for a PDF response.
HttpContext.Current.Response.ClearHeaders()
HttpContext.Current.Response.ClearContent()
HttpContext.Current.Response.ContentType = "text/html"
HttpContext.Current.Response.AppendHeader("Content -Disposition",
"filename=""FinancialReport.pdf""")
httpContext.Current.Response.BinaryWrite(report)
HttpContext.Current.Response.End()

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.