Quantcast
Channel: SCN : Discussion List - SAP Crystal Reports, version for Visual Studio
Viewing all 3636 articles
Browse latest View live

memory leak with windows service

$
0
0

Hi,

 

comparable to description of memory leak, I still do have the same problem.

The application runs as a windows service on Windows Server 2012.

I'm using Crystal Report v13.0.13 for .NET (x64 , Framework 4.5.2) with visual studio 2013.

Accourding to the "Fixed issues" at http://scn.sap.com/docs/DOC-7824 this problem has not been fixed in th newer releases.

 

The problem exits since we migrated the project from 32-bit to 64-bit and from VS 2008 to VS2013.

It is definitly Crystal R. that does not free the memory correctly.

 

Which further informations do you need to fix this bug?

 

Thanks in advance!


Crystal Reports 2008 Runtimes

$
0
0

I've looked and looked, but I'm not able to find the runtimes for Crystal Reports 2008. Where can I get these?

How to add Sum and Max function

$
0
0

I have created a c# vs2012 windows application with latest version of CR. The datasource for my report is XML file which have information as product name, quantity sold, price, SaleDate, etc. I have created a report which shows Product Name and Quantity. It shows like this

 

Product Name     Quantity    SaleDate

A                         2               2016-01-01

A                         3               2016-02-01

B                         5               2016-02-01

C                         7               2016-02-02

A                         6               2016-02-02

A                         2               2016-02-05

B                        15              2016-02-06

C                        10              2016-02-07

 

Till here it is working fine.

 

Now I want to create a report like this:

 

Product Name     Quantity         SaleDate

A                         13               2016-02-05

B                         20               2016-02-06

C                         17               2016-02-07

 

Quantity = SUM(Quantity) for every product

SaleDate = Max(SaleDate) for a product

 

Is this possible in my report. Please suggest if there are any documentation/steps to achieve this.

 

Thanks

Create Report from MYSQL and c#

$
0
0

How do I bind my crystal report with mysql database? I have a windows application with a button and a crystal report viewer. On button click it should get data from MYSQL and show it over here.

CR for VS SP16, Align Objects not available?

$
0
0

In Visual Studio 2015, with CR for VS SP16 installed, having difficulty with alignment tools.  I have similar objects selected (2 lines) but all of the alignment choices in the toolbar are greyed out.  Both items selected are in the same section.

 

Additional Info:

Just opened the report in Crystal Reports Designer 2013 SP7 with same result.

 

Update 2:

I was able to manually adjust with 400% zoom.

 

Checked a few things, some of the objects had extend to bottom of section when printing.  I turned off that property with no effect.

 

This is not a big deal, thought it might be worth discussing since the align feature is very handy.

Crystal reports 2008 12.3.3.812 - Runtime installation customer skips pages

$
0
0

We've integrated the Crystal Report viewer in our software using the SDK.

 

A customer has a report were the result of the report in the previewer shows 5 pages. If I export the report to PDF it shows the same 5 pages. If I export the report to Crystal Report with the saved data and I open the report in my Crystal Report 2008 designer I see 7 pages.

 

I looked closely at the differences and some data is missing at the customer compared to the version in the designer. If I however export the report to Excel all the data is shown in Excel even the rows missing.

 

What might be the cause and how can I resolve this.

 

Thanks for any help

 

Btw I have an example PDF and the corresponding RPT file with the data, but I'm not able to attach these file types.

Crystal Report for VS2013, data connection for Oracle

$
0
0

Hello,

 

The default data connection for the reports are Microsoft OLE DB Provider for Oracle, which is discontinued by MS, and no 64bit verison.

May i know how to enable oracle driver for <Crystal Report for VS 2013>, it seems that there is no such option for selection,

even, I have set PATH to %ORACLE_HOME%\instant client, pointing to ORAOCI*.dll or have install ODAC, it is no use.

 

Since i has the following error,

 

Logon failed.
Details:
ADO Error Code: 0x80004005
Source: Microsoft OLE DB Provider for Oracle
Description: Oracle client and networking components were not found.
These components are supplied by Oracle Corporation and are part of the Oracle Version 7.3.3 or later client software installation

 

Platform used:
Windows 2012R2 64 bit
Oracle client 64 bit 12c Release 1
Visual studio 2013
Crystal report for VS 2013(x64) version 13.0.2

 

so, i has to change to Oracle Driver, but there is no such option provided. thank you for your help.

Dynamic image won't display - Different circumstances

$
0
0

VS2013 asp.net application using CR_for_VS_13_0_16.compiled in .net Framework 4.0

I am using a parameter to pass the graphic location to the report. This works on the development PC but fails on 2 different test servers hosted by different companies. In the MS-SQL database I only carry the logo file name. Because I host in more than one location, I build up the parameter value by using Server.Mappath() along with the file name in my code and I come up with the full physical path of the graphic. (That is also how I load my reports). I have qualified the resulting path by displaying the parameter on the report itself, then drilling down in the web site control panel to see that the graphic exists. I have also confirmed that the web user has read capabilities to the graphic.

I have used Fiddler and it shows   ;:[{&#39;paramName&#39;:&#39;pLogo&#39;,&#39;description&#39;:&#39;Enter pLogo:&#39;,&#39;valueDataType&#39;:&#39;s&#39;,&#39;value&#39;:[&#39;E:\\HostingSpaces\\paulray\\<myserver>.com\\wwwroot\\sites\\ct\\images\\db-edit.bmp&#39;]

I am not sure if the double hacks are the issue (\\) and not sure how they get doubled?

This is how I pass all my report parameters.... NOTE: sLogo is the qualified URL to the graphic

.

Select Case crParameterField.Name

Case "pLogo"

                            Dim crParameterValues = crParameterField.CurrentValues

 

                            '' Destroy the previous instance and create a new instance.

                            crParameterDiscreteValue = Nothing

 

                            ''Set the current values for the parameter field

                            crParameterDiscreteValue = New ParameterDiscreteValue()

                              " Pass parameter if not NULL

                            If Not sLogo Is DBNull.Value Then

                                crParameterDiscreteValue.Value = Server.MapPath(sLogo)

                            Else

                                crParameterDiscreteValue.Value = ""

                            End If

                            ''Add the first current value for the parameter field

                            crParameterValues.Add(crParameterDiscreteValue)

.

Keep in mind, it does work locally.  Also I think I have read all the other posts but could not come up with anything.

Ideas? Thanks in advance.

Paul


PrintMode.PrintOutputController Doesn't Recognize Saved Paper Tray Setting

$
0
0

SP14, Cr4VS, Winform, vb.net

 

In Crystal Designer, a choice of paper tray (e.g., Tray 3) is recognized in future print sessions as demonstrated by this image: 2015-07-28_1442 - IdoMillet's library

 

However, when opening the same reports, on the same machine, via a winform application using the PrintMode.PrintOutputController the print dialog doesn't recognize the saved paper tray. Here is an image of the dialog: http://screencast.com/t/GmHi3mgW7

 

Will this be fixed in a future SP?  If not, what is the recommended solution?

Unable to cast object of type 'FileStreamDeleteOnClose' to type 'System.IO.MemoryStream'.

$
0
0

I have been running many Crystal Reports on Windows 2012 Server for 2+ years and everything works great.

 

I just built a new Windows 2012 Server and the same code/reports are crashing.  See below.

 

Code:

 

MemoryStream mStream;

 

mStream = (MemoryStream)crystalReport.ExportToStream(ExportFormatType.PortableDocFormat);

 

Error:

 

Unable to cast object of type 'FileStreamDeleteOnClose' to type 'System.IO.MemoryStream'


 

 

I am not sure why it's working on old server and not the new one.

Please advise.

 

Thanks,

Yury

Failed to open the connection with pull crystal report 10 VS 2010

$
0
0

I Have issue with my existing visual studio application whihc was developed in VS 2005 framework 2 and sql 2005. later that was migrated to vs 2008 and now to visual studio 2010 with any CPU option and framework 4. Now it shows issue as in the question, while generating all pull reports from the application whereas my push reports are working perfectly. pleae note that only the framwork and VS has changed whereas my crystal report (10 for pull) or sql server 2005 has not been changed.

 

The report is populating in design mode with crystal 10 and and its DSN. however application has the code to do the auto creation of DSN and seems that also creating as all these while it was working.

 

Please help me to sort out this...

Crystal Reports: problem displaying justified text on the right

$
0
0

Hi!

i have a problem with crystal report for visual studio 2010

i try to display justified Arabic text on a text object/formula, the problem is the text does not show correctly on the viewer or printed

 

i tried to use rtf text and html text but nothing works

 

please help!

 

here is a little picture of my problem attached

 

cr2010.png

Update : I just tried with Visual Studio 2013 and CRforVS_13_0_13 still not working

Crystal Report always hang when running on a web application

$
0
0

I develop a report for my web application, and for some reason, it always hang if I try to generate the report from the production server.

I identify the culprit as the printer being used in the Crystal Report. By default, the report uses a network printer, which is not available on the production server. If I change the printer to "Microsoft XPS Document Writer" or "No Printer", it seems to work.

 

But what is weird is that I've been using the network printer to develop the report for other projects and was deployed to other server (which does not have the network printer as well), and it seems to run fine. Only in this server it does not work. Is there any configuration setting that I've to do in the server?

 

Crystal Report version: 14.1.4.1327

Visual Studio 2015 Update 1

SubReports can't be opened in CrystalReportViewer

$
0
0

I'm using Visual Studio 2013 and I'm trying to open reports created by Crystal Reports XI. Where I work, there are about 900 reports that other members of the dev team need to be able to open (they don't have CR installed on their machines) and I've been asked to create a utility that can open a report and show the SQL query that created the report. I've inserted a CrystalReportViewer control on my winform and use the Crystal Reports SDK to load a report into it and extract the query.

When the report opens, a window for editing the parameters for the main report opens, but not for the subreport. As a result, the main report opens in the viewer, and I can get the SQL for it and I get an error message telling me parameters are missing for the subreports. How do I bring up the parameter window for the subreports?

Below is the code I use to load the reports, the error occurs at getSQL. I call login and getSql from a button click handler:

privateReportDocument cryRpt, crySubRpt;//report and subreport documents

privateTableLogOnInfos crTableLogonInfos;

privateTableLogOnInfo crTableLogonInfo;

privateConnectionInfo crConnectionInfo;

privateSections crSections;

privateTablesCrTables;

privateReportObjects crReportObjects;

privateSubreportObject crSubreportObject; 

 

privatevoid login()

{

crConnectionInfo.ServerName="SQLANYWHERE16"; 

loginMainReport();

loginSubReport();

popoulateReportViewer(); 

}//end void login 


privatevoid loginMainReport()

{

  CrTables= cryRpt.Database.Tables;

  foreach(CrystalDecisions.CrystalReports.Engine.Table aTable inCrTables)

  {

crTableLogonInfo = aTable.LogOnInfo;

crTableLogonInfo.ConnectionInfo= crConnectionInfo;

aTable.ApplyLogOnInfo(crTableLogonInfo);

  }

}//end loginmainreport 


privatevoid loginSubReport()

{

  // set the sections object to the current report's section

crSections = cryRpt.ReportDefinition.Sections;

  // loop through all the sections to find all the report objects

  foreach(Section crSection in crSections)

  {

crReportObjects = crSection.ReportObjects;

  //loop through all the report objects in there to find all subreports

  foreach(ReportObject crReportObject in crReportObjects)

  {

  if(crReportObject.Kind==ReportObjectKind.SubreportObject)

  {

crSubreportObject =(SubreportObject)crReportObject;

  //open the subreport object and logon as for the general report

crySubRpt = crSubreportObject.OpenSubreport(crSubreportObject.SubreportName); 


foreach(CrystalDecisions.CrystalReports.Engine.Table aTable inCrTables)

  {

crTableLogonInfo = aTable.LogOnInfo;

crTableLogonInfo.ConnectionInfo= crConnectionInfo;

aTable.ApplyLogOnInfo(crTableLogonInfo);

  }//end foreach table atable

  }//end if crReportObjectKind

  }//end foreach reportobject

  }//end foreach section

}//end loginsubreport 


privatevoid populateReportViewer()

{


crystalReportViewer1.ReportSource= cryRpt;

crystalReportViewer1.Refresh(); 

}//end void populateReportViewer 


privatevoid getSQL()

{

  CrystalDecisions.ReportAppServer.ClientDoc.ISCDReportClientDocument boReportClientDocument;

  CrystalDecisions.ReportAppServer.Controllers.RowsetController boRowsetController; 

  string temp ="";

  string mainSqlQuery ="";

  string subSqlQuery =""; 

  try

  {

  // Access the ReportClientDocument in the ReportDocument boReportClientDocument = cryRpt.ReportClientDocument; 

  //Get the Rowset controller to access the sql query boRowsetController = boReportClientDocument.RowsetController;

mainSqlQuery = boRowsetController.GetSQLStatement(newCrystalDecisions.ReportAppServer.DataDefModel.GroupPath(),out temp); 

//output the query

outputToTextBox("-- main report sql query: "+Environment.NewLine+ mainSqlQuery +Environment.NewLine); 

  // get subreport sql

foreach(string subReportName in boReportClientDocument.SubreportController.GetSubreportNames())

  {

//open the subreport

  SubreportClientDocument boSubReportClientDocument = boReportClientDocument.SubreportController.GetSubreport(subReportName); 

  //Get the Rowset controller to access the subs sql query

  RowsetController boSubRowsetController = boSubReportClientDocument.RowsetController;

subSqlQuery = boSubRowsetController.GetSQLStatement(newCrystalDecisions.ReportAppServer.DataDefModel.GroupPath(),out temp); 


//output the subreport query

outputToTextBox("-- subreport: "+ subReportName +Environment.NewLine+"-- report sql query: "+Environment.NewLine+ subSqlQuery +Environment.NewLine);

  }

  }catch(Exception ex)

  {

  MessageBox.Show(ex.ToString());

  }

}//end void getSQL

different result when print using crystal report viewer and PrintOutputController.PrintReport

$
0
0

Hi.

I'm using VS 2015

and CR v13,SP16

i am using user defined paper 12 x 14 cm,

 

when print using PrintOutputController.PrintReport the result become smaller than it should be.

when print using CRViewer the result is good and as it should be. but user must set the preferences to user defined paper size and the other printer setting. even though my default setting from control panel has been set.

 

is there anyways to make it programatically sett all of the properties?


datasource for R is setted with another function.

this is my printing code

 

 

                PrintDocument pDoc = new PrintDocument();

                PrinterSettings dPrinterSett = new PrinterSettings();

                PageSettings dPageSetting = new PageSettings();

               

                PrintOptions printOption = R.ReportClientDocument.PrintOutputController.GetPrintOptions();

                printOption.DissociatePageSizeAndPrinterPaperSize = false;

                printOption.PaperSize = CrPaperSizeEnum.crPaperSizeUser;

                printOption.PrinterDuplex = CrPrinterDuplexEnum.crPrinterDuplexSimplex;

 

 

                PrintReportOptions printReportOption = new PrintReportOptions();

                printReportOption.PaperSize = CrPaperSizeEnum.crPaperSizeUser;

                printReportOption.Collated = true;

               

 

 

                R.ReportClientDocument.PrintOutputController.ModifyPrintOptions(printOption);

                R.ReportClientDocument.PrintOutputController.ModifyPrinterName(dPrinterSett.PrinterName);

                R.ReportClientDocument.PrintOutputController.ModifyUserPaperSize((dPageSetting.PaperSize.Height * 1440/100),                                                                                                                         (dPageSetting.PaperSize.Width * 1440/100));

 

 

                if (pDoc.DefaultPageSettings.PaperSize.Height > pDoc.DefaultPageSettings.PaperSize.Width)

                {

                    R.ReportClientDocument.PrintOutputController.ModifyPaperOrientation(CrPaperOrientationEnum.crPaperOrientationPortrait);

                }

                else

                {

                    R.ReportClientDocument.PrintOutputController.ModifyPaperOrientation(CrPaperOrientationEnum.crPaperOrientationLandscape);

                }

               

                R.ReportClientDocument.PrintOutputController.PrintReport(printReportOption);

 

Any Help is appreciated,

Thankyou..


Could not load file or assembly 'log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The system cannot find the file specified

$
0
0

I have gone through several discussions on the same issue. Unfortunately none of those posts helped me out. This is my problem.

 

-> I have developed asp.net website in my local machine and

-> Deployed in my local network with CR13.0.5. It is working fine.

-> Notable point here is, in this working environment, I can see SAP Crystal Report for Runtime engine .NET Framework(64 bit) and SAP Crystal reports, versions for Microsoft visual studio in control panel.

This was deployed a year ago.

 

Now what i am doing is,

-> In another server I tried to deploy the same application.

-> I could not get the same version of CR. So I have installed runtime from this link http://downloads.businessobjects.com/akdlm/cr4vs2010/CRforVS_redist_install_64bit_13_0_1.zip

-> Now I can see only SAP Crystal Report for Runtime engine .NET Framework(64 bit).

-> While running the application, I get the above mentioned error.

 

Please help me out to resolve this issue.

Report Paper Source

$
0
0

I am working with the new HP Universal Print Driver.  The Report.PrintOptions.PaperSource always returns auto.  Even when I select the tray in the printer properties screen it returns to auto. How can I fix this?  I need to be able to save the printer source. I have reports that need to print to specific trays. This has worked for years!  

EPL printing with .net sdk

$
0
0

We had a crystal report integration for EPL base label printing which is implemented from VB6. We migrated it to .net and now one report is working butnot others. When we check the working report only different we found is that font of text object is set as "Device Font 10cpi". I checked even with a simple application with hard coded values it only works with the one which has set the font. But when i print with CR designer it works. What couble be he reason

 

I could not find ant way to set that font from CR designer. Any idea how to set that

 

Sample code

var reportDocument = new ReportDocument();

reportDocument.Load(_reportFilePath);

var viewer = new CrystalReportViewer { ReportSource = reportDocument };

viewer.RefreshReport();

viewer.PrintReport();

 

following is the  EPL script

 

I8,1,046

q400

S3

OD,N

JF

j112

WN

D10

ZB

Q240,32

N

B24,6,0,1,2,5,72,N,"Test"

A10,100,0,2,1,2,N,"Test"

A10,140,0,2,1,1,N,"Test"

A10,160,0,2,1,1,N,"Test"

A10,200,0,2,1,1,N,"Test"

A10,220,0,2,1,1,N,"Test"

A390,16,1,1,1,1,N,"Test"

A365,16,1,1,1,1,N,"Test"

A340,16,1,1,1,1,N,"Test"

A315,16,1,1,1,1,N,"Test"

P1

N

 

Printer we are using is Zebra - GT800

Where do I get the ASP.NET runtime for Crystal Reports 2016?

$
0
0

We have an ASP.NET application that must present reports that were authored in Crystal Reports 2016. We are using the "CrystalReportViewer" control. What is the correct runtime that needs to be installed on the web servers hosting our ASP.NET application in order to display these Crystal Reports 2016 reports?

 

Thanks!

H

Empty result against Oracle Server 11 on Windows 2012

$
0
0

I have an problem when executing an report against an Oracle Server 11 on a Windows Server 2012 (Customer system). The result have empty

pages. It contains only formula fields/calculated fields.

 

There is no problem if I execute the report against an Oracle 11 Server that does not run on a Windows Server 2012 (our Test system got Windows Server 2008). So only the change of the connection information in the report causes this problem. The report will be executed by the same Environment (my developer computer). So every executing component is identical. We are using an own software that uses the crystal report runtime (without IIS). It is only possible to get a valid result against the customer system when executing the report from the Crystal Report 2011-Developer Tool.

 

Details:

Customer system: Windows Server 2012 R2 Datacenter 64Bit with Oracle Server 11.2.0.4, CRRuntime_64bit_13_0_14

Developer environment: Windows 7 Ultimate 32Bit with Oracle client 11.2.0, CRRuntime_32bit_13_0_3, Crystal Reports 2011

Viewing all 3636 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>