Showing posts with label pdf. Show all posts
Showing posts with label pdf. Show all posts

Tuesday, March 27, 2012

Authorization ticket not received by LogonUser

Hello I am getting an error "Authorization ticket not received by
LogonUser" when trying to render an inline pdf report. It only happens
in VB.Net though.
I think that my authcookie is not being set for some reason.
Some info
I have created this app from scratch(modeled after adventureworks
sample in VB) and modified the adventureworks sample(c#)
the c# sample works but the vb.net does not.
I have set both my webCookie.Domain and netcookie.domain to
".domain.com" <- my domain
The sql server, IIS server and the webreports application are on the
same machine.
If I use the reportViewer control (vs 2003) it works fine and the when
I ask for Request.Cookies.AllKeys
I get
ASP.NET_SessionId
.ASPXAUTH
sqlAuthCookie
as the cookies listed.
This s a good sign but when I call the render function rs.render(all my
parameters) I get the error in vb.net only. Could it be a bad
translation on my part?
THis function may have been translated wrong.
Protected Overloads Overrides Function GetWebResponse(ByVal request As
WebRequest) As WebResponse
Dim response As WebResponse = MyBase.GetWebResponse(request)
Dim cookieName As String = response.Headers("RSAuthenticationHeader")
' If the response contains an auth header, store the cookie
If Not (cookieName Is Nothing) Then
Utilities.CustomAuthCookieName = cookieName
Dim webResponse As HttpWebResponse = CType(response,
HttpWebResponse)
Dim authCookie As Cookie = webResponse.Cookies(cookieName)
' If the auth cookie is null, throw an exception
If authCookie Is Nothing Then
Throw New Exception("Authorization ticket not
received by LogonUser")
End If
' otherwise save it for this request
authCookie = authCookie
' and send it to the client
Utilities.RelayCookieToClient(authCookie)
End If
Return response
End Function 'GetWebResponse
Any sugestions would be much appreciated.
Thanks
MoOne thing I forgot to add is I am using forms authentication and it
seems to be working fine up to the rendering point.|||Are you using forms authentication in the september 2005 CTP by chance?
"M0" wrote:
> One thing I forgot to add is I am using forms authentication and it
> seems to be working fine up to the rendering point.
>

Friday, February 24, 2012

Attn Bruce Johnson [MSFT] Re: RS do not follow PDF specification?

Bruce,
I am not sure if you read my reponse to your question in the old thread. So I am re-posting here the answer I got from the ActivePDF's support team. BTW, are there any plans at Microsoft to fix this?
Thanks.
Regards,
Alexander Korygin.
-----
Information from ActivePDF QA department:
A bug in SQL Server Reporting Services causes PDF's to be created with the startxref tag pointing to one byte short of the start of the xref table.
This causes Toolkit to fail to open the file because it isn't a valid PDF.
I've already submitted this issue to Engineering to see if they can come up with a fix to work around this issue until Microsoft can provide a fix for SQL Server Reporting Services, which, as I understand it is due mid this year.
You can work around this issue by opening the PDF in Acrobat, and doing a Save As, and Acrobat will repair the PDF.
-----
"Bruce Johnson [MSFT]" wrote:
> I did some research on this issue and there is a known bug that covers this
> issue. We would be interested in knowing what portion of the PDF
> specification you think is not being followed correctly.
>
> --
> Bruce Johnson [MSFT]
> Microsoft SQL Server Reporting Services
>
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
> "Alex Korygin" <AlexKorygin@.discussions.microsoft.com> wrote in message
> news:2330E4E1-588E-4C1C-ACF0-B03378D80E97@.microsoft.com...
> > Hi,
> >
> > our company produces complex PDF reports for customers. One major
> requirement is to be able to merge the reports, rendered by Reporting
> Services SP1 web service in PDF format into existing documents. The problem
> is that the ActivePDF server can not open and merge the PDFs, produced by
> RS. The ActivePDF's tech support team says there is a problem with the
> Microsoft Reporting Tool not following the PDF specification. Can someone
> from MSFT confirm / refute this?
> > Thanks.
> >
> > P.S. I am quoting the ActivePDF response here:
> > ----
> > Looking further into this, the issue is with Microsofts reporting tool.
> It's not creating the PDF properly under PDF specs. Toolkit is not designed
> to fix PDF's that do not follow PDF Specs.
> >
> > Microsoft is apparently going to fix this issue with a Service Pack in the
> future. Until then Toolkit will not be able to work with these files.
> > ----
> >
> > --
> > Regards,
> >
> > Alex Korygin.
>
>
>I did see your earlier post. To the best of my knowledge the information you
provided is covered by an existing bug.
The fix for it will appear in a future release.
--
Bruce Johnson [MSFT]
Microsoft SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"Alex Korygin" <AlexKorygin@.discussions.microsoft.com> wrote in message
news:BCC32EEA-50A3-4FFC-828A-4B0ABDBF3698@.microsoft.com...
> Bruce,
> I am not sure if you read my reponse to your question in the old thread.
So I am re-posting here the answer I got from the ActivePDF's support team.
BTW, are there any plans at Microsoft to fix this?
> Thanks.
> Regards,
> Alexander Korygin.
>
> ----
--
> Information from ActivePDF QA department:
> A bug in SQL Server Reporting Services causes PDF's to be created with the
startxref tag pointing to one byte short of the start of the xref table.
> This causes Toolkit to fail to open the file because it isn't a valid PDF.
> I've already submitted this issue to Engineering to see if they can come
up with a fix to work around this issue until Microsoft can provide a fix
for SQL Server Reporting Services, which, as I understand it is due mid this
year.
> You can work around this issue by opening the PDF in Acrobat, and doing a
Save As, and Acrobat will repair the PDF.
> ----
--
>
> "Bruce Johnson [MSFT]" wrote:
> > I did some research on this issue and there is a known bug that covers
this
> > issue. We would be interested in knowing what portion of the PDF
> > specification you think is not being followed correctly.
> >
> > --
> > Bruce Johnson [MSFT]
> > Microsoft SQL Server Reporting Services
> >
> > This posting is provided "AS IS" with no warranties, and confers no
rights.
> >
> >
> > "Alex Korygin" <AlexKorygin@.discussions.microsoft.com> wrote in message
> > news:2330E4E1-588E-4C1C-ACF0-B03378D80E97@.microsoft.com...
> > > Hi,
> > >
> > > our company produces complex PDF reports for customers. One major
> > requirement is to be able to merge the reports, rendered by Reporting
> > Services SP1 web service in PDF format into existing documents. The
problem
> > is that the ActivePDF server can not open and merge the PDFs, produced
by
> > RS. The ActivePDF's tech support team says there is a problem with the
> > Microsoft Reporting Tool not following the PDF specification. Can
someone
> > from MSFT confirm / refute this?
> > > Thanks.
> > >
> > > P.S. I am quoting the ActivePDF response here:
> > > ----
> > > Looking further into this, the issue is with Microsofts reporting
tool.
> > It's not creating the PDF properly under PDF specs. Toolkit is not
designed
> > to fix PDF's that do not follow PDF Specs.
> > >
> > > Microsoft is apparently going to fix this issue with a Service Pack in
the
> > future. Until then Toolkit will not be able to work with these files.
> > > ----
> > >
> > > --
> > > Regards,
> > >
> > > Alex Korygin.
> >
> >
> >
>
>

Sunday, February 19, 2012

Attachment file is invalid.

Hello,

I have a stored procedure with this syntax

declare @.filename varchar(100)

set @.filename='c:/A.pdf'

EXEC msdb.dbo.sp_send_dbmail

@.profile_name =@.p_profile

@.recipients = @.p_address,

@.body = @.p_body,

@.subject = @.p_subject,

@.file_attachments = @.filename

but when I execute it i have an error

Attachment file c:/A.pdf is invalid.

What's happen? Thanks in advance

hi,

It seems you are trying to load the file from invalid path. Change to

@.filename='C:\A.pdf' instead of 'c:/A.pdf'

Also make sure that A.pdf file is availed in C Drive.

|||Moving to the Transact-SQL forum.

Thursday, February 16, 2012

Attaching files

I have just started using ASP.net.
I have to develop a system that attaches word and PDF files to form. I also need to be able to do a full text search on the documents attached.
I'm currently using SQL server 2000 as my backend DBMS, but I have never used it to attach files. My mates recommend using BLOGS but I'm not sure how to do this and I'm not sure if I can do a full text search using this solution.
Could some body please recommend a solution to get me started.
Thanks in advanced
PaddyYou have two requirements because Word and PDF files are better stored as IMAGE while FULL TEXT uses TEXT and NTEXT. FULL TEXT is an add on to SQL Server dependent on Microsoft Search and the Catalogs must be populate to get search results. Run a search for FULL TEXT, CONTAINS, CONTAINSTABLE, FREETEXT and FREETEXTTABLE in the BOL(books online). Hope this helps.

Thursday, February 9, 2012

attach some extra pdf documents ?

how do I add some extra pdf documents into my report pages it depends on db
bit field value ?
regards
ilkerYou cant add directly instead you can provide a hyperlink where by users will
click and get the PDF.
Amarnath, MCTS
"ilker tiryaki" wrote:
> how do I add some extra pdf documents into my report pages it depends on db
> bit field value ?
> regards
> ilker|||On Mar 12, 3:30 am, ilker tiryaki
<ilkertiry...@.discussions.microsoft.com> wrote:
> how do I add some extra pdf documents into my report pages it depends on db
> bit field value ?
> regards
> ilker
If you are needing to have a portion of the report to export to PDF
based on a bit field in the database, you can either use a subreport
in the report that only returns data for cases of the bit field being
set -or- do the same with a table in the report. I think you should be
able to toggle the visibility based on the dataset that will populate
this extra section. If you are looking to just include external PDF
documents, I believe that Amarnath is correct.
Regards,
Enrique Martinez
Sr. SQL Server Developer