Running Crystal Reports in a batch service.

Post Author: RichardP
CA Forum: General
I have set a Windows service to a run a Crystal Reports, and the code is as follows:-
Public Class WebForm1
Inherits System.Web.UI.Page
Dim crReport As New ReportDocument
Dim strConn As String = ConfigurationSettings.AppSettings("WebOASISConn")
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
End Sub
Protected WithEvents CrystalReportViewer1 As CrystalDecisions.Web.CrystalReportViewer
'NOTE: The following placeholder declaration is required by the Web Form Designer.
'Do not delete or move it.
Private designerPlaceholderDeclaration As System.Object
Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
End Sub
#End Region
Public Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
'CrystalReportViewer1.ReportSource = New WebServ5.STPMBReportService
'Dim NewServ1 As New WebServ5.service
Dim crConnectionInfo As New ConnectionInfo
Dim crConnServer As String = ConfigurationSettings.AppSettings("CrConnServer")
Dim crConnDbName As String = ConfigurationSettings.AppSettings("CrConnDbName")
Dim crConnUserId As String = ConfigurationSettings.AppSettings("CrConnUserId")
Dim crConnPassword As String = ConfigurationSettings.AppSettings("CrConnPassword")
'Dim err As String
'Try
crConnectionInfo.ServerName = crConnServer
crConnectionInfo.DatabaseName = crConnDbName
crConnectionInfo.UserID = crConnUserId
crConnectionInfo.Password = crConnPassword
'C:\Inetpub\wwwroot\WebServ5
'crReport.Load("http://localhost/WebServ5/STDPOReportService.asmx")
crReport.Load("http://localhost/WebServ5/STDPOReportService.asmx")
' crReport.Load(Server.MapPath("STDPOReportService.asmx"))
' Catch ex As Exception
'Err = ex.Message
'End Try
'(Server.MapPath("STDPOReport.rpt"))
'Dim reportName As Request.QueryString = "STDPOReport"
'CrystalReportViewer1.LogOnInfo.Add(CObj(crConnectionInfo))
'rystalReportViewer1.LogOnInfo.Item()
SetLogOnInfo(crConnServer, crConnDbName, crConnUserId, crConnPassword, "due_in")
SetLogOnInfo(crConnServer, crConnDbName, crConnUserId, crConnPassword, "stores_item")
SetLogOnInfo(crConnServer, crConnDbName, crConnUserId, crConnPassword, "unit_info")
'CrystalReportViewer1.ReportSource = "http://localhost/WebServ5/STDPOReportService.asmx"
CrystalReportViewer1.ReportSource = crReport
Dim myTable As CrystalDecisions.CrystalReports.Engine.Table
Dim MyLogonInfo As CrystalDecisions.Shared.TableLogOnInfo
For Each myTable In crReport.Database.Tables
'&#91;With MyLogonInfo.ConnectionInfo
'End With
MyLogonInfo.ConnectionInfo = crConnectionInfo
myTable.ApplyLogOnInfo(MyLogonInfo)
Next
End Sub
Private Sub SetLogOnInfo(ByVal server As String, ByVal database As String, _
ByVal userID As String, ByVal password As String, ByVal _
table As String)
Dim logOnInfo As New TableLogOnInfo
logOnInfo = crReport.Database.Tables.Item(table).LogOnInfo
' Set the connection information for the table in the report.
logOnInfo.ConnectionInfo.ServerName = server
logOnInfo.ConnectionInfo.DatabaseName = database
logOnInfo.ConnectionInfo.UserID = userID
logOnInfo.ConnectionInfo.Password = Password
logOnInfo.TableName = table
End Sub
End Class
But when I attempt to run it I get this message:-
Server Error in '/WebApp5' Application.
Load report failed.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: CrystalDecisions.CrystalReports.Engine.LoadSaveReportException: Load report failed.
Source Error:
Line 56:         crConnectionInfo.UserID = crConnUserId
Line 57:         crConnectionInfo.Password = crConnPassword
Line 58:         crReport.Load("http://localhost/WebServ5/STDPOReportService.asmx")
Line 59:
Line 60:
Source File: c:\inetpub\wwwroot\WebApp5\WebForm1.aspx.vb    Line: 58
Stack Trace:
&#91;LoadSaveReportException: Load report failed.&#93;
   &#91;1&#93;.&#91;1&#93;I(String   , EngineExceptionErrorID  )
   &#91;1&#93;.&#91;1&#93;E(String  , Int32  )
   CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String reportName, OpenReportMethod openMethod, Int16 parentJob)
   CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String reportName)
   WebApp5.WebForm1.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\WebApp5\WebForm1.aspx.vb:58
   System.Web.UI.Control.OnLoad(EventArgs e)
   System.Web.UI.Control.LoadRecursive()
   System.Web.UI.Page.ProcessRequestMain()
Version Information: Microsoft .NET Framework Version:1.1.4322.2032; ASP.NET Version:1.1.4322.2032
Any ideas anyone?

Hi,
I came across this and a hundred other problems when
trying to integrate Crystal into our application
framework. I agree with the previous post - crystal
either don't have a testing department for the JRC or
don't care about us :(
Anyhow, the solution I found was to create a pretend,
wrapper JDBC connection driver, which I fix in my
web.xml to the ODBC name my reports use. When the
Crystal control transfers to the connect method of my
driver, I route it to the correct database with
credentials and return a connection from the real
JDBC driver. Works a treat.
Hope this helpsHi,
How and where do you 'route' your handmade connection to JRC?
I set the user and password as in the documentaion described to the ConnectionInfo - collection, provide this to the viewer and nothing works...
When appending user & password info to the jdbc connect url (definied in web.xml, jndi) the report runs. But this solution isn't very flexible ...

Similar Messages

  • Error when running crystal report

    i saw the error in log file 'Only TrueType fonts are supported. This is not a TrueType font' and 'Error while running Crystal report'
    Help me to fix this problem.Thanks inadvanced.
    I used some software developed in vb6.It changed some system font when running :D.
    i want to run both that soft   and sap.

    Hi,
    Please refer to the link, [Re: CR XI R2, Crystal Report Viewer Opentype Font not supported|Re: CR XI R2, Crystal Report Viewer Opentype Font not supported].
    What is the version of your crystal report, we will try to apply some service packs.
    Regards,
    Clint

  • Error while running Crystal Reports from application

    Hi,
    I am getting the below error when I try to run Crystal Reports from my application.
    There are no Page Servers connected to the Cache Server or all connected Page Servers are disabled or all connected Page Servers are not part of the specified server group. Please try to reconnect later.
    I am able to preview the reports in CMC and Infoview, but when I try to run the same report via my application the above error pops up.
    Sometimes I get a different error:
    The Page Server you are trying to connect to is not accessible. Please contact your system administrator.
    Looks like some configuration settings are missing/ corrupted.
    I tried to look in a number of websites... tried few workarounds, but none seems to be working.
    Any help is highly appreciated.
    Meena
    Edited by: meenakshitikoo1 on Apr 19, 2011 12:46 PM

    Check the following SAP note
    https://service.sap.com/sap/support/notes/1032461
    Regards,
    Stratos

  • Running Crystal Reports in background mode

    Ist there any way to run Crystal Reports against R/3 (ECC) in background mode instead of as a dialog user? We're having timeout issues since the dialog timeout is set to 30 minutes. We have several reports that run quite a bit longer than that.
    Update: I just answered my own question. Pages 58-59 of the install and configuration guide shows you how to do this.
    Edited by: Mike Garrett on Jan 22, 2009 4:57 PM
    Edited by: Mike Garrett on Jan 22, 2009 8:41 PM

    Hi,
    SIA should be all you need because it is starting the other processes as well. Keep in mind that if you do that that most likely all you reports will run in batch mode (also those called on demand.)
    Ingo

  • When deleting running crystal report from BOE CMC, it leaves Oracle thread?

    hi,  Yesterday, we discovered an anomaly.  From BOE's CMC, I deleted a running Crystal Report instance. I believed that this would "cancel" the running report. However, later, it produced a message.  It apparently kept on running in Oracle until it finished.
    My question: when I delete a job from BOE's CMC, what else must we do to cancel it from continuing in Oracle? Apparently, it continued to be a "thread" in Oracle.
    What additional steps should I take or are there any setup steps?  Thank you.
    Our BOE version (copied from the CMC about screen) is: Product: 12.1.0 © 2008 Business Objects (or Product Version:      12.2.0.290).
    Thank you,
    Dean

    I'd just been trying instructions in SAP note: 1407795 when this reply came through.... I can confirm this worked for me.
    The error codes I found in the Windows Event viewer, both yesterday and today are listen below:
    RCIRAS0240
    RCIRAS0622
    RCIRAS0567
    RCIRAS0244
    The issues that are described in this post and the ones I have seen first-hand  when the screen hangs when viewing this report on-demand, or the report running for a longer than expected time when scheduled, are covered by the above error codes. 
    A known cause of the issues you are experiencing is that when these particular reports were created, a network printer was specified as the default printer, this printer may now either be unavailable, IP address may have changed, etc.
    There do seem to be two options available:
    Option 1 - Remove the printer driver dependency
    Open this report in the Crystal Reports Designer.
    Under the File menu, click on Page Setup.
    Select the No Printer option.
    Option 2 - Add or correct the printer that the report is designed with
    Open the Report in the Crystal Reports Designer
    Under the File menu, click on Page Setup
    Make not of the printer that is listed in the Page Setup dialog
    Log on to the BusinessObjects Enterprise Server that houses the Crystal Reports Processing Servers.
    Make sure you log in as the user account that runs the Crystal Reports services.  This is generally the account that runs the Service Intelligence Agent (SIA)
    Go to Control Panel and click on Printers
    Ensure that the same printer is configured on the server that is used in the Crystal Report
    In the printer already exists, try removing it and re-adding it.

  • Crystal Reports Schedule using Batch File

    Hi,
    I am trying to automatically export Crystal Reports using a Batch file and Windows Task Scheduler. It sucessfully opens Crystal, but doesn't perform the export.
    "C:\Program Files\Business Objects\Crystal Reports 11.5\crw32.exe" "C:\reportname.rpt" /X 36 /D 1 /FN "C:\report export name.xls"
    Any help would be greatly appreciated.
    Thanks,
    Nick
    Edited by: NickHofmeyr on Apr 26, 2010 11:22 AM

    Hello,
    Sorry but CR doesn't support command line running of reports. You can use Crystal Reports Server, Businessobjects Enterprise or some third party tool that uses Crystal runtime.
    Thank you
    Don

  • Unable to run Crystal Report due to error code called "database code:102

    I have created a View on the SQL server and Now I am trying to run crystal report using that view. However, I get Database Vendor Code error message 102. Need your help, How can I ran a report using SQL veiws in Crystal?
    thanks!
    Mansoor

    Hi,
    The report is getting an error code 102  from the database driver.Try with searching the RDBMs type for error code 102, to narrow down the issue.
    If  data from database is failed to retrieve then,there are several causes of this error like disconnected tables, tables that are not connected properly.
    Run your query in SQLcon32 and check that getting accurate output or not.
    Regards,
    Shweta

  • Error While running crystal report

    Dear All,
    i have some crystal reports in SAP.while opening any crystal report its through some error like  "Error While running crystal report ".
    Kindly suggested me how to do this .
    Thanks&Regards,
    P.Pratap

    Hi All,
    Thanks for your reply,
    already i close this Issue.
    they have one addon for crysatl report .so it show error like Error while Running crystal report
    thanks&Reagrds,
    P.Pratap

  • Running Crystal Reports

    How do I restrict users to being able to run Crystal Reports via "schedule" only? (version X1)

    You can use WEB.SHOW_DOCUMENT('URL of the Crystal Reports Server and pass the necessary parameters.');

  • Issues in running crystal reports 2013 with SOQL as a datasource

    Hi Experts,
    We have some crystal reports created in CR 2008 with command as a data source and all the commands are written in SOQL pulling data from SFDC, now when I open and run those reports in crystal report designer 2013 it is giving below errors:
    Failed to retrieve data from the database.
    Details: 42S22:[Simba][SQLEngine] (31400) Qualified column could not be bound: c.Investor__r.Relationship_Formula__c. [Database Vendor Code: 31400 ]
    Failed to retrieve data from the database.
    Details: 42S22:[Simba][SQLEngine] (31400) Qualified column could not be bound: k.Account_Relationship__r.PE_Priority__c. [Database Vendor Code: 31400 ]
    We are running crystal reports in both the version with system admin user who has access to all the objects in SFDC. It works well for CR 2008 but not for CR 2013, means relationship is not an issue.
    We have done some analysis and found that if the field in query contains two periods (.) it is not recognising that field, if we remove that field from query, CR 2013 takes that as a valid statement.
    Any help or suggestions on this issue would be a great help.
    Regards,
    Apoorv

    Hi Apporv
    Please check your database documentation for error 31400.
    - Ludek
    Senior Support Engineer AGS Product Support, Global Support Center Canada
    Follow us on Twitter

  • Run crystal report through BI, can't locate par file on BOBJ server

    Attempting to run crystal report through BI iView. 
    Followed steps here: http://wiki.sdn.sap.com/wiki/display/BOBJ/CreateBOEXI3.1IntegrationKitIViewTemplateintoSAPEP+Portal
    successful until we try to locate the par file:
    com.businessobjects.pct.masteriview.par
    Is there something we need to install to be able to load this file, or is there somewhere we can download.
    As of now, stopped b/c can't find
    com.businessobjects.pct.masteriview.par

    Thanks Ingo, would this be the correct file to download and install?
    Download BusinessObjects XI 3.1 Java Portal Integration Kit - WAR 10 MB
    Located here:
    http://www.sdn.sap.com/irj/boc/enterprise;jsessionid=(J2EE3414800)ID1586935850DB11532971180627469992End?rid=/webcontent/uuid/503988db-58c5-2b10-f79d-cb96700417f9
    then click Download BusinessObjects XI 3.1 Java Portal Integration Kit - WAR 10 MB
    to get here:
    http://www.sdn.sap.com/irj/boc/index?rid=/library/uuid/f0c30ff1-4e75-2c10-a385-8eff81c946aa
    We currently have BOBJ set up, CMC/INFOVIEW, and crystal linked to SAP BI...so I thought we'd installed everything we need, I guess this is more for portal...b/c now our goal is to see what crystal reports look like in BI portal instead of infoview.
    thanks a lot,
    matt

  • How generate a crystal reports layout for Batch Report

    Dear Experts,
    I want to create a crystal reports layout for Batch Report that appears when printing Delivery Note.
    I've tried using DocKey@ token but it only works in the delivery note layout itself. The following code at the select expert for this crystal layout doesn't work:
    {ODLN.DocEntry} = {?DocKey@}
    Kindly guide me in the above issue. Thanks.

    I am using version 8.8 SP.00 PL.10
    It is very strange that I cannot get the layout connected to the database as I have followed the same steps for all layouts. It all works fine until I get to the invoice stage and then I cannot make the connection.
    (I dont need to worry about the sales invoice as this was provided at installation point by our vendor)

  • Crystal Report as a Hosting Service

    Post Author: Shahoo
    CA Forum: General
    Hi friends.
    I have not much info about crystal report. Our company is a web hosting one, and a few of the clients of our windows hosting have requested us to include crystal report in our offered services. I like to know that is it common to do this?! Because I've heard that crystal report eats much resources and is some heavy. Also, our CP is Plesk.
    So briefly, my questions are:1) is it safe to install crystal report in our plesk machine?
    2) is there any lightweight solution? for example, different crystal report versions and choosing one of them...?
    Thank you for any comments.

    Thanks for your response. Unfortunately I do not see a radio button for Web Services. I've read that it should be there too. Could it be a missing plug-in or patch?
    Here are screen shots of what I see when trying to connect to an XML. Any thoughts?
    [http://s26.photobucket.com/albums/c120/hpolit/?action=view&current=wizard1.jpg]
    [http://s26.photobucket.com/albums/c120/hpolit/?action=view&current=wizard2.jpg]

  • Running Crystal Report through web service

    We are trying to build a solution using Java, which will give access of Crystal reports to users. We are trying to access using the Web Services provided by BO XI server.
    I need help with couple of issues I'm facing with the consumer API -
    1. When a search is performed and reports/documents are found, how to get the path (parent folder(s)) of that document?
    2. How to run a report? I've tried schedule (method of BIPlatform) with 'RightNow' property (of SchedulingInfo object) to true, but it throws exception 'Pause and Resume isnt allowed'. But through CMC I can run the report on demand.

    Just to give more info on what I'm doing in my code -
    I'm searching for a report with it's name. Search is performed by BICatalog web service's search operation. It returns an array of BICatalogObject. Now I'm unable to find a method to get the path info of these objects. I see there's a class named PathFolder in API javadoc, but cant find a method of BICatalogObject that can return such objects.
    Can anyone help me out with this?

  • Running a crystal report xi in batch mode (C# runs a crystal report xi in batch mode)

    <p>Does anyone know if it is possible in a C# program to submit a Crystal Report XI? </p><p>Our design is to use C# front end to prompt the user for the parameters for the report.  These parameters would be stored in a table.  At night the C# program would wake up and based on the parameters, the C# program would submit the crystal report to run.</p>

    hi..
    am using .net version 2005 and crystalreports version 9.0
    i pass value from crystalreportviewer page to crystal reports design page using parameter fields but they take only first row data only...
    i want to display dynamic values .. values are passed correcltly but not displayed... all fields dispalyed same  value from database first row..
    is there any solutions .. please reply me..
    my mail id: [email protected]

Maybe you are looking for

  • Configuration error while creating index in KM

    Hi KM Expets, I am getting the following error while creating a new index via System Adminstration > System Configuration > Knowledge Management > Index Adminstration. Index could not be created; creating index failed: Invalid entry in configuration:

  • Difference in Ar01 and General ledger balance for Accumulated Depreciation

    Dear all, I am facing a peculear problem that my Accumulated Depreciation amount which is not matching with AR01 repoert and My Accumulated Deprecaition G.L a/c from FS10n. Last year it was matchning. I am useing ECC 5.0 version of SAP. I am assuring

  • Code Interface Nodes and multithreading (openMP)

    Hi, We are experiencing a rather strange problem with the use of Code Interface Nodes (CIN) in LabView. The CINs are built with the Intel Compiler in the Visual Studio .NET 2003 IDE and use the openMP directives to easily implement multithreading. Th

  • Primary (Internal) Battery for HP G50

    I have the following notebook computer Model: NP531UA  HP G50-213CA NB PC FCAN On startup, I get the following message HP Battery Alert The system has detected the storage capacity of the battery stated below to be very low. For optimal performance,

  • DPS6: Unable to retrieve a backend SEARCH connection to process the search

    I have installed and configured DPS 6 but I cannot get it to proxy through to our back-end Sun DS 5.2 servers. The error message I get is: Error while reading entry  [LDAP: error code 1 - Unable to retrieve a backend SEARCH connection to process the