Server Threw Exception when Exporting the report as PDF

Hi ,
I am developing a .Net application , In my application referring to the .rep file which is created using the Business Objects Desktop Intelligence as below
  objBO = new busobj.Application();
                    objBO.Logon(strUserName, strPassword, strServerName, strConnectionMode,false, false);
                    objBO.Visible = false;
                    objBO.Documents.OpenFromEnterprise("PfILS Document.rep", strDomain, BoEnterpriseFolderKind.boFolder);
After passing the values to the variables of the.rep and refreshing like as below
objBO.Application.ActiveDocument.Refresh();
when I tried to save the generated report as .pdf ..
objBO.Application.ActiveDocument.ExportAsPDF(@"c:\" + Report0101010 + ".pdf");
I am getting the following issue
The server threw an exception. (Exception from HRESULT: 0x80010105 (RPC_E_SERVERFAULT))
and the application fails to export the report to pdf document
Please help me , what will be root cause of this issue
Thanks
Babu
Edited by: Babu Lakshmikantham on Oct 28, 2009 9:18 AM

Hi,
World you like to have a look at the sample [here|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60b54507-de66-2b10-95b8-a89015297027]?
Hope that helps!
Thanks.

Similar Messages

  • Problem when exporting the report to PDF viwer a 45,000-page report

    I am using Visual Studio 2013 with the report vivew.
    I have a report that works correctly, however when generating a 45000 pages he is giving memory error when exporting to PDF, any tips?

    Check this SAP Note: 1089388     Incorrect value in exported PDF when Concat function is used
    [https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/smb_searchnotes/display.htm?note_langu=E&note_numm=1089388]

  • Logon Failed when exporting crystal report to PDF

    Hi, I am Teguh
    i want to ask about error when export crystal report to pdf
    error message
    CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed
    [LogOnException: Logon failed.]
       .I(String , EngineExceptionErrorID ) +506
       .D(Int16 , Int32 ) +537
       .C(Int16 ) +10
       CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext) +577
       CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportFormatType formatType) +141
       Falcon.CRTransferSlip.Page_Load(Object sender, EventArgs e) in C:\inetpub\wwwroot\Falcon\CRTransferSlip.aspx.vb:77
       System.Web.UI.Control.OnLoad(EventArgs e) +67
       System.Web.UI.Control.LoadRecursive() +35
       System.Web.UI.Page.ProcessRequestMain() +750
    environment:
    OS : Windows server 2008 standard SP1
    IIS: Version 7.0
    SQL: Sql server 2000
    VS : Visual studio 2003
    i really confused with this error,
    please help me for this problem
    many thank's

    Hi Ludek
    Thank you for your response. I have installed SP3 and ProcMon and still the same result.
    I applied a filter on ProcMon to filter out items where the path contains 'export'.
    There are a few items where the result is 'NAME NOT FOUND' but I don't think it necessarly had anything to do with the barcode. These include items such as 'EXPORT\MailDestType','EXPORT\DisableExportLiveOfficeSupport'','EXPORT\ExportDirectory' to name a few.
    What drew my attention was the ACCESS DENIED result on specifically the EXPORT\PDF folders. The detail for these are  Desired Access : All access, however the very same entry appears a little futher on as a SUCCESS but this is detailed as Desired Access: Query Value.
    So in summary it looks something like this:
    User : Server\XXX
    Operation : RegOpenKey
    Path : HKU\.DEFAULT\Software\Business Objects\Suite 12.0\Crystal Reports\Export\Pdf
    Result : ACCESS DENIED
    Desired Access : All Access
    User : Server\XXX
    Operation : RegOpenKey
    Path : HKU\.DEFAULT\Software\Business Objects\Suite 12.0\Crystal Reports\Export\Pdf
    Result : SUCCESS
    Desired Access : Query Value
    There are a few other entries that follow this pattern that exists in other locations such as HKLM\Software...
    Could this 'ACCESS DENIED' be the problem? and If so how do I, and should I give user XXX this ALL Access its looking for.
    Regards
    Elroy

  • Getting IllegalThreadStateException, while exporting the report to PDF

    Hi Friends,
    I am using JRC to create report in PDF format.
    But intermitently I get java.lang.IllegalThreadStateException while trying to export ReportClientDocument into PDF format using the PrintOutPutContrller.
    The I am using for this is
    ExportOptions exportoptions = new ExportOptions();
    PDFExportFormatOptions pdfOptions = new PDFExportFormatOptions();
    exportoptions.setExportFormatType(ReportExportFormat.PDF);
    exportoptions.setFormatOptions(pdfOptions);
    reportInputStream = reportClientDocument.getPrintOutputController().export(exportoptions);
    The exception I get is:
    com.crystaldecisions.sdk.occa.report.lib.ReportSDKException: java.lang.IllegalThreadStateException---- Error code:-2147467259 Error code name:failed
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.if(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.solidcore.as.report.ReportJob.createPDFReport(ReportJob.java:114)
    at com.solidcore.as.report.ReportJob.execute(ReportJob.java:66)
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
    at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
    I am using JRC that comes with CR4E 2.0. The Report is designed using Crystal Report 2008.
    Please help me in solving the issue.
    Thank you,
    Deepak

    Hi Ted,
    Thank you for the answers.
    In our applications the Report will be generated in two ways.
    1. A user clicks on a link on web, and the report is generated in PDF format and sent via http.
                At present we are creating a new
                ReportClientDocument for every request and using ExportControl.processHttpRequest() API
                the report in PDF format is sent user through response.
    2. Quartz schuduler trigger a job, whose work is to generate Report in PDF format into a file, and the
              generated pdf file is sent to users via mail.
              Here I user ReportCLientDocument.export() API to get the InputStream and use the input stream
              to create PDF file.
    It is possible that a user is requesting a report on Web Page and the same report is being generated by Scheduler at the same time. But in each case a separate ReportClientDocument is being used.Since Report containse a huge data, and it takes time to generate PDF file so, it is possible that a given RPT file is opened by two spearate ReportClientDocuemnt (one via web user and other via Scheduler) at the same time.
    The have got rid of my earlier exceptions by sycncronizing the ReportClientDocuent.export() API.
    But now am getting following exception intermittently.
    2009-05-01 16:47:45.859 GMT+05:30 [ERROR] [ReportJob.java:137] [AnalyticsScheduler_Worker-10(34)] - [] Could not generate the Report.
    java.lang.NullPointerException
         at com.crystaldecisions.sdk.occa.report.application.ds.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.if(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
         at com.solidcore.as.report.ReportJob.createPDFReport(ReportJob.java:123)
         at com.solidcore.as.report.ReportJob.execute(ReportJob.java:75)
         at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
         at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
    2009-05-01 16:47:45.859 GMT+05:30 [ERROR] [JobRunShell.java:211] [AnalyticsScheduler_Worker-10] - Job reportJobGroup.reportJob threw an unhandled Exception:
    java.lang.NullPointerException
         at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.if(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.case(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ClientDocument.close(Unknown Source)
         at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.close(Unknown Source)
         at com.solidcore.as.report.ReportJob.createPDFReport(ReportJob.java:155)
         at com.solidcore.as.report.ReportJob.execute(ReportJob.java:75)
         at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
         at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525)
    Edited by: Deepak Mishra on May 4, 2009 5:47 PM

  • Failed to export the report to PDF

    I am currently developing multiple applications using Visual Studio 2008 and Crystal Reports. The application works fine in the development environment but when deployed to a user's machine I get the error listed below.
    I installed the redistributable package that came with Visual Studio. Then I installed my packed. I check in the users GAC that the assemblies I used in developing are installed. They are present on the users machine.
    I have not found much on this subject online. Does anyone know of a solution to this issue? Was installing the redistributable package that came with Visual Studio 2008 correct? Any help would be great.
    Not implemented.
    Failed to export the report.
    Error in File C:\DOCUME~1\USER~1\LOCALS~1\Temp\1\temp_a4f4905b-85ec-4420-ae7e-f1a57ecd3f44 {CDBECA9C-8D45-4BEE-949F-F6CF818AB575}.rpt:
    Operation not yet implemented.
       at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
       at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportOptions options)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportFormatType formatType)
       at Condor.Threading.PortfolioAnalysisPDFThread.StitchReport(List`1 crReports)
       at Condor.Threading.PortfolioAnalysisPDFThread.CreateReport(DoWorkEventArgs e)

    Hi Ludek ,
    Thanks for reply,
    I download CR2008 Redistribale & Installed it.
    But still I am getting following  error on client PC;
    at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
       at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext)
       at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToDisk(ExportFormatType formatType, String fileName)
    Please  give  solution.
    Thanks

  • Error on server while trying to export a report into PDF using JRC (CR XI)

    13/01/2009        11:52:32            dataengine        ERROR Formula error: recompile formulas failed
    com.crystaldecisions.reports.formulas.FormulaException: Exception in formula '{@Record Selection}' at '{reports_selection.idReport}':
    This field name is not known.
    13/01/2009        11:52:32            JRCCommunicationAdapter        ERROR Failed to export report
    com.crystaldecisions.reports.exportinterface.exceptions.ExportException: Exception in formula '{@Record Selection}' at '{reports_selection.idReport}':
    This field name is not known.
    The error occurs only on the server deployed application, in localhost environment it works fine. So I guess it might have something to do with the server environment, but I can't figure it out. The table reports_selection and the field idReport are well presented in the database.
    The idReport(Number) is passed as a parameter to the report.
    In Select expert... I have the following  formula {table1.idReport} = {?idReport} and in Database expert... I have a join between table1 and reports_selection by idReport.
    Does anyone know what might cause this problem?

    Have you able to preview the report via the Central Management Console?
    When you upload the report template to the server, be sure to do a preview to make is sure its working there.
    It might be that your server is using a different DB Connection.
    Edited by: Rulix Batistil on Jan 14, 2009 10:38 AM

  • Operation not yet implemented when exporting crystal report to pdf

    Thank you in advance,
    When running the line **** export within the following code, I am getting the following error message:
    "Error in File C:\DOCUME1\rborda\LOCALS1\Temp\TimeDetailTest {00DC8730-45CD-4A29-8854-C44BBD5B5230}.rpt: Operation not yet implemented."
    I tried the following solution registering dlls, but still did not solve the problem above:
    regsvr32 "C:\Program Files\Common Files\Crystal Decisions\2.0\bin\crtslv.dll"
    regsvr32 "C:\Program Files\Common Files\Crystal Decisions\2.0\bin\ExportModeller.dll"
    regsvr32 "C:\Program Files\Common Files\Crystal Decisions\2.0\bin\tslv.dll"
    CODE:
    Imports CrystalDecisions.CrystalReports.Engine
    Imports CrystalDecisions.Shared
    Imports CrystalDecisions.ReportAppServer
    Imports CrystalDecisions.Web
    Imports CrystalDecisions.ReportSource
    Partial Public Class _Default
        Inherits System.Web.UI.Page
        Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        End Sub
        Private Sub btnRunReport_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnRunReport.Click
            'Try
            Dim ConInfo As New CrystalDecisions.Shared.TableLogOnInfo
            Dim oRptDoc As New ReportDocument
            Dim expo As New ExportOptions
            Dim oDiskFileDestinOption As New DiskFileDestinationOptions()
            Dim strCrystalReportFilePath As String
            Dim strPdfFileDestinationPath As String
            Dim crParameterDiscreteValue As ParameterDiscreteValue
            Dim crParameterFieldDefinitions As ParameterFieldDefinitions
            Dim crParameterFieldLocation As ParameterFieldDefinition
            Dim crParameterValues As ParameterValues
            strCrystalReportFilePath = "C:\TimeDetailTest.rpt"
            strPdfFileDestinationPath = "C:\TimeDetailTest0814.pdf"
            oRptDoc.Load(strCrystalReportFilePath) 'loads the crystalreports in to the memory
            'Create parameter objects
            'Provide Parameter values
            crParameterFieldDefinitions = oRptDoc.DataDefinition.ParameterFields
            crParameterFieldLocation = crParameterFieldDefinitions.Item("StartPeriod")
            crParameterValues = crParameterFieldLocation.CurrentValues
            crParameterDiscreteValue = New CrystalDecisions.Shared.ParameterDiscreteValue
            crParameterDiscreteValue.Value = #7/6/2008#
            crParameterValues.Add(crParameterDiscreteValue)
            crParameterFieldLocation.ApplyCurrentValues(crParameterValues)
            crParameterFieldLocation = crParameterFieldDefinitions.Item("EndPeriod")
            crParameterValues = crParameterFieldLocation.CurrentValues
            crParameterDiscreteValue = New CrystalDecisions.Shared.ParameterDiscreteValue
            crParameterDiscreteValue.Value = #8/2/2008#
            crParameterValues.Add(crParameterDiscreteValue)
            crParameterFieldLocation.ApplyCurrentValues(crParameterValues)
            'Export Information
            oDiskFileDestinOption.DiskFileName = strPdfFileDestinationPath    'path of file where u want to locate ur PDF
            oRptDoc.ExportOptions.DestinationOptions = oDiskFileDestinOption
            oRptDoc.ExportOptions.ExportDestinationType = ExportDestinationType.DiskFile
            oRptDoc.ExportOptions.ExportFormatType = ExportFormatType.PortableDocFormat
           oRptDoc.Export()
        End Sub
    End Class

    I got the same error message when trying to export a report to Excel format.  This happened with an existing report that had always exported with no problem, until I added a couple of new formulas. After investigating, I discovered that one of my formulas was returning a divide by zero error if a date range was too small.  Once I fixed that formula, it began exporting again with no problem.  I discovered this by trying to export to PDF (since all of the situations discussed here involved PDF) and that was when it returned the divide by zero error.

  • Has anyone been able to get a book's internal bookmark hyperlinks working when exporting the book as PDF?

    When a PDF-version of a book is viewed within Preview, bookmark hyperlinks do not work, but they do work on iPad.
    In this support page, Apple states that hyperlinks should work.
    Has anyone got a successful workaround that doesn't involve adding hyperlinks, one by one, via Preview?
    Cheers,
    Tim

    Hi Ken.
    By "Preview", I refer to the Apple Preview app on my iMac; 'Preview' displays the PDF but the hyperlinks within the PDF will not link through to their respective pages throughout the book. Each hyperlink displays underlines, and the 'hyperlink' mouse icon displays when hovering over a hyperlink. It's just that the links won't work. There are hundreds of bookmarks, so adding these manually from within 'Preview' is not a viable option.
    Any thoughts?
    Tim

  • Changing default color scheme when exporting ALV report to Excel spreadshee

    Hi all,
    We have a bunch of FI reports created using OOPS in abap.  Each of the reports has the functionality to be exported to an excel spreadsheet.  When exporting to Excel, the headers are a very dark brown color, making them difficult to read and it has been requested that they are shaded a lighter color.  I have not defined any sort of color scheme within the report itself, and I was wondering if there was a way to change the color scheme when exporting the report to excel.  Let me know if there is anything that can be done, thanks!

    check ur fcat

  • Poor image quality when exporting a report to Word

    Hi,
    We are developing an application where users can download exported Word 2003 or PDF documents generated by Crystal Reports. The problem is that when the format type in the export options is set to Word for Windows the quality of the images in the document degrades immensely. The PDF images are looking fine though.
    Literally, the only difference between the two exports is that only one of these lines executes depending on what the user selects when exporting the report.
    crxReport.ExportOptions.FormatType = CRAXDRT.CRExportFormatType.crEFTPortableDocFormat;
    crxReport.ExportOptions.FormatType = CRAXDRT.CRExportFormatType.crEFTWordForWindows;
    I am using Crystal Reports 10.0. Upgrading to Service Pack 6 did not seem to solve the problem. This service pack resolves a similar problem that occurs with PDFs but it's Word documents we're having trouble with. The project we are working on is a .NET 1.1 project and it is hosted in a machine running Windows 2003 Standard Edition with Service Pack 2.
    Any help is greatly appreciated
    L.

    Hello Logan:
    See if the directions in [this|http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_erq/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes.do] note help.
    [This|http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_erq/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes.do] note is not quite what you'd look for, but it may be worth considering to see if it helps.
    Other than that, as Ido recommended, despite the difficulties of the number of parameters, see if exporting from the CR designer is any different. If it is not, we're fighting a lost battle. Alternatively, you could create a new report in the CR designer, no database connection needed. Insert an image, export.
    Ludek

  • No link after exporting Crystal report as pdf file

    Hello,
              If my Crystal Report contain link to the .avi file saved on the local hard disk and if I export the Report as .pdf file, pdf file does not contain that link. Why?
    The overall scenario is like-
    My application fires a query on SQL Server database and result of that query is stored in a Dataset. This dataset is set as a datasource to the Crystal report.  Now some, records (returned by the query) have .avi files(i.e. Event Videos which are stored on the local hard disk) associated with them. I have stored these .avi files in a specific path on local Hard disk say "C:/EventVideos/*.avi" .   I used a special format in these avi files name. (like - "EventVideo_1.avi" (This is for 1st event), "EventVideo_5.avi" (This is for 5th event)etc. to identify which avi is for which event. All events do not have avi files associated with them)
          Now, I take one object in crystal report. Using it's Format editor created a formula for hyperlink as -
          "file:///c:/EventVideos/EventVideo_" + {DataTable1.EventID} + ".avi" .
    EventID is the field of dataset which has ID's (like 0, 1, 2,  3, 4 etc) of all resulted events. It is of a String data type.
         Now when I export, my report as .xls, .rtf, .doc, I can open the avi files. When I bring cursor on this object, cursor get change to Hand and after click on it avi file start to play.
         But if I export it as .pdf, it does not contain the link for avi files. When I bring cursor on this object, it does not change to Hand, and after click on it nothing happens. No video play.
    I stick to this problem.
    Appreciate your help.
    Thanks in advance.

    Taken from CR Help File:
    "PDF format is a page-based format. The exported documents are intended for printing and redistribution. PDF format will export both layout and formatting in a manner that is consistent with how the report looks on the Preview tab. PDF format embeds the TrueType fonts that appear in the document. (Non-TrueType fonts are not supported.) This export format does not support Microsoft font-linking technologyu2014which is used to provide support for some extended character sets such as Chinese HKCS. Therefore, the fonts used in the report must contain all of the required glyphs. These URI types are supported for hyperlinks: "http:", "https:" and "mailto:".
    Therefore your hyperlink is not working as u are using File type when cr only supports http https and mailto uri types

  • Problem to export a report (to PDF) after converting my reports to CR13

    I have an old project with reports developped using Crystal Reports for Visual Studio 2003 (.NET 1.1). I want to convert them so I can now use Crystal Reports for Visual Studio 2010 (with .NET 3.5).
    I installed Crystal Reports for VS2010 and I converted my reports to the new format. Unfortunately, one of my reports is not working anymore.
    My ASP.NET application generate the report and export it as a PDF. I use CrystalDecisions.CrystalReports.Engine.ReportDocument.Export().
    Everytime I run this method, an exception is thrown...
    System.Exception was unhandled by user code
      Message=System.Runtime.InteropServices.COMException (0x80041004):
    Mémoire insuffisante pour l'opération.
       à CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext)
       à CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
       à CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
       à CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext)
       à CrystalDecisions.CrystalReports.Engine.FormatEngine.Export()
       à CrystalDecisions.CrystalReports.Engine.ReportDocument.Export()
       à
      Source=GSPRapport
      StackTrace:
    I also tried to export the report (using PDF format) at design time with the "Export Report" button in Preview mode. It didn't work. But, I can export the report at design time using another format type (like XML).
    The old version of te report (using .NET 1.1, CR9) work fine. As I said, other reports in that same project work perfectly.
    Is someone have an idea of what's wrong!
    Thanks!
    Max.

    The most common cause of this problem is having very large detailed images, or lots and lots of images in your report. The Crystal Report engine changed a lot from 9.1 to 13. The big change was from 9.1 to 10 though when we started using the RAS InProc engine.
    The Crystal reporting engine is not efficient at handling the images and it can cause memory issues like you are seeing. As a test, try suppressing the images that show up frequently in your report and retry your export. If it works you'll have your answer and you'll need a new creative way to design your report without so many images.

  • Error occurred during exporting ssrs report as pdf

    an error occurred during local report processing. Object reference not set to an instance of an object
    Thanks in advance

    Hi Esha2nk,
    According to your description, when you export the report to PDF in BIDS, the error “Export error: An error occurred during local report processing. Object reference not set to an instance of an object.” is thrown out.
    Based on the error message, it could cause by that there are hidden groups within the report, or the matrix has multiple columns and rows, and Hidden is set to true in the Visibility properties. So in your scenario, please check those two factors. If
    issue persists, please provide report design for our analysis. Besides, would you please tell us which SQL Server version you are using?
    Reference:
    "An error occurred during
    local reporting processing. Object reference not set to an instance of an object."
    Object reference not set to an instance of an object
    If you have any question, please feel free to ask.
    Best regards,
    Qiuyun Yu
    Qiuyun Yu
    TechNet Community Support

  • Exporting Crystal Report to pdf

    Hi,
    We have a crystal report that is stored in Business Objects Enterprise XI 3.1. The requirement is to connect to the Enterprise and export the report as pdf in .NET web page. I see a lot of RAS samples. But we are required to use the Business Objects Enterprise sdk dlls for this purpose.
    Can somebody provide me a sample for this.
    Thanks
    Irene

    Hi Adam,
    Yes I am trying to use the Page Server option of RAS to open the report. That is only one working due to firewall restrictions.
    But I was trying to set the report parameters in the report Object and assumed that it should be reflected when opening the report. But that does not seem to work. So now what I did is,  I tried to set the report source to report viewer control and change the parameters through code.
            boEnterpriseService = boEnterpriseSession.GetService("PSReportFactory");
            boReportAppFactory = (PSReportFactory)boEnterpriseService.Interface;
            ISCRReportSource objRep = boReportAppFactory.OpenReportSource(boInfoObject.ID);
            CrystalReportViewer1.ReportSource = objRep;
            CrystalDecisions.Shared.ParameterFields  objFields = CrystalReportViewer1.ParameterFieldInfo;
            CrystalDecisions.Shared.ParameterDiscreteValue objDis = new CrystalDecisions.Shared.ParameterDiscreteValue();
            objDis.Value = "Product Category";
            objFields[0].CurrentValues.Clear();
            objFields[0].CurrentValues.Add(objDis);
            CrystalReportViewer1.ShowFirstPage();
    So the report shown in the viewer is opened with the parameters specified. But now I have the problem of exporting. I need to export this report with the parameters specified in code to pdf.
    What are the options. I tried using the CrystalDecisions.CrystalReports.Engine.ReportDocument so I can do the export but am getting Communication Failure:FWM 0001.
    Is there any way of directly exporting the report from the viewer without user intervention ?
    Thanks
    Irene

  • Using SSRS local mode, receive invalid token error when trying to export the report when running in worker thread

    We're using ASP.net with .Net 4, developing with Visual Studio 2012.  We use SSRS 2012sp1 with local reports, so exporting the report ourselves instead of using a reportviewer control (and not using the SQL Reporting service).  The reports are
    executing fine when we export the report in the main thread, but if we spawn a worker thread and run a report there we receive the following error when calling Render():
    Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Failed to load expression host assembly. Details: Invalid token for impersonation - it cannot be duplicated.
    We only receive this when running a report that uses expressions on a separate thread.  I've tried running the application pool under all the default built-in accounts (NetworkService, etc), and under admin user accounts to no avail.
    This didn't occur with the previous version of our application which used .net 3.5.

    As mentioned, we are not using the Reportviewer control, we are rendering locally.  Not certain if that would make a difference.
    Also, I had tried using all the built-in accounts.  Just for kicks I changed it to LocalSystem again, then reset IIS (see image below).  I then tried to export the report in a worker thread and received the same error.
    Here is the text from the exception:
    Microsoft.Reporting.WebForms.LocalProcessingException: An error occurred during local report processing. ---> Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Failed to load expression host assembly. Details: Invalid token for impersonation - it cannot be duplicated.
    at Microsoft.ReportingServices.RdlExpressions.ReportRuntime.ProcessLoadingExprHostException(ObjectType assemblyHolderObjectType, Exception e, ProcessingErrorCode errorCode)
    at Microsoft.ReportingServices.RdlExpressions.ReportRuntime.LoadCompiledCode(IExpressionHostAssemblyHolder expressionHostAssemblyHolder, Boolean includeParameters, Boolean parametersOnly, ObjectModelImpl reportObjectModel, ReportRuntimeSetup runtimeSetup)
    at Microsoft.ReportingServices.OnDemandProcessing.Merge.Init(Boolean includeParameters, Boolean parametersOnly)
    at Microsoft.ReportingServices.OnDemandProcessing.Merge.Init(ParameterInfoCollection parameters)
    at Microsoft.ReportingServices.ReportProcessing.Execution.ProcessReportOdp.CreateReportInstance(OnDemandProcessingContext odpContext, OnDemandMetadata odpMetadata, ReportSnapshot reportSnapshot, Merge& odpMerge)
    at Microsoft.ReportingServices.ReportProcessing.Execution.ProcessReportOdp.Execute(OnDemandProcessingContext& odpContext)
    at Microsoft.ReportingServices.ReportProcessing.Execution.RenderReportOdpInitial.ProcessReport(ProcessingErrorContext errorContext, ExecutionLogContext executionLogContext, UserProfileState& userProfileState)
    at Microsoft.ReportingServices.ReportProcessing.Execution.RenderReport.Execute(IRenderingExtension newRenderer)
    at Microsoft.ReportingServices.ReportProcessing.ReportProcessing.RenderReport(IRenderingExtension newRenderer, DateTime executionTimeStamp, ProcessingContext pc, RenderingContext rc, IChunkFactory yukonCompiledDefinition)
    at Microsoft.Reporting.LocalService.CreateSnapshotAndRender(ReportProcessing repProc, IRenderingExtension renderer, ProcessingContext pc, RenderingContext rc, SubreportCallbackHandler subreportHandler, ParameterInfoCollection parameters, DatasourceCredentialsCollection credentials)
    at Microsoft.Reporting.LocalService.Render(String format, String deviceInfo, String paginationMode, Boolean allowInternalRenderers, IEnumerable dataSources, CreateAndRegisterStream createStreamCallback)
    at Microsoft.Reporting.WebForms.LocalReport.InternalRender(String format, Boolean allowInternalRenderers, String deviceInfo, PageCountMode pageCountMode, CreateAndRegisterStream createStreamCallback, Warning[]& warnings)
    --- End of inner exception stack trace ---
    at Microsoft.Reporting.WebForms.LocalReport.InternalRender(String format, Boolean allowInternalRenderers, String deviceInfo, PageCountMode pageCountMode, CreateAndRegisterStream createStreamCallback, Warning[]& warnings)
    at Microsoft.Reporting.WebForms.LocalReport.InternalRender(String format, Boolean allowInternalRenderers, String deviceInfo, PageCountMode pageCountMode, String& mimeType, String& encoding, String& fileNameExtension, String[]& streams, Warning[]& warnings)
    at Microsoft.Reporting.WebForms.LocalReport.Render(String format, String deviceInfo, PageCountMode pageCountMode, String& mimeType, String& encoding, String& fileNameExtension, String[]& streams, Warning[]& warnings)
    at Microsoft.Reporting.WebForms.Report.Render(String format, String deviceInfo, String& mimeType, String& encoding, String& fileNameExtension, String[]& streams, Warning[]& warnings)
    at IxSS.Infolinx.Report.MicrosoftInfolinxReport.ExportReport(String strFileFullyQualifiedPath, String strExportType, String strFilterDesc, Dictionary`2 extraParams, String area)
    at IxSS.Infolinx.Report.MicrosoftInfolinxReport.ExportReport(String strFileFullyQualifiedPath, String strExportType, String strFilterDesc, Dictionary`2 extraParams)

Maybe you are looking for

  • IPhone 5s will not show in Itunes 11.3 after update

    Hi Folks, Updated iTunes to 11.3.0.54 and restarted my machine (running win 8.1).  Now when I dock the IPhone (5s running 7.1.2) it shows the 'Trust' prompt and when accepted, sounds a tone, then does nothing.  ITunes does not show any phone connecte

  • Firefox (latest versions) on both Mac 10.6 and Windows 7 show "this Connection is Untrusted" on my bank site

    This started for me 1/17/2011 on the savingsbank.com website: Firefox (latest versions) on both Mac 10.6 and Windows 7 show "this Connection is Untrusted" on my bank site https://www.savingsbank.com NO other browsers - Explorer, Chrome, Safari - give

  • Which is better transfer routine or update routine???

    HI ALL, I have read some documents, but I didnt get the real concept. Can any one explain in detail as to how do we decide where to write the code i.e a start routine or transfer routine or update routine...and which one is better  for a given scenar

  • Battery BA800

    i need a new original battery for my xperia V? where can i buy it?

  • Using Third Party APIs with Tomcat and Axis

    I'm experimenting with creating web services in Java. I'm using tomcat and axis for this. I have successfully created and deployed some basic web services and now I want to create one using a 3rd party API. I follow the same exact procedure and when