?
Solved

Unable to preview a report that uses two subreport on non development machine

Posted on 2008-02-03
5
Medium Priority
?
400 Views
Last Modified: 2013-11-15
I have created my reports using ttx file. The main report uses 2 subreports. The subreports have same linking parameter (StationId). I pass data to report using ADO Recordset. The reports work fine on a development machine with crystal report XI installed on them, however, it fails on a test (deployment) machine (both win 2k professional and WinXP). All other reports that do not have subreports work fine everywhere.
I am not sure if there is a problem with the report or I am not ditributing right files?
Do I need to distribute additional file for subreports?

I include following merge module in my installshield program (Installshield Express XI):
CR_11_License ver 1.0
CR_11_reprtengine ver 1.0
CR_11_rdc_runtime ver 1.0.


Here is the code that passes data to the report
(the first field of all the recordset is StationId)
m_objReport is defined as ICRDesigner
objRsMainReportData is defined as Recordset
objRsSubReport1Data is defined as Recordset
objRsSubReport2Data is defined as Recordset
 
Dim objReportUnit As CRAXDRT.Report
Dim objReportHW As CRAXDRT.Report
 
    m_objReport.Database.SetDataSource objRsMainReportData
 
    If Not objRsSubReport1Data Is Nothing Then
        Set objReportUnit = m_objReport.OpenSubreport(m_objReport.Subreport1.SubreportName)
        objReportUnit.Database.SetDataSource objRsSubReport1Data
    End If
    If Not objRsSubReport2Data Is Nothing Then
        Set objReportHW = m_objReport.OpenSubreport(m_objReport.Subreport2.SubreportName)
        objReportHW.Database.SetDataSource objRsSubReport2Data
    End If

Open in new window

0
Comment
Question by:nbandari
  • 2
4 Comments
 
LVL 101

Expert Comment

by:mlmcc
ID: 20809782
I am not aware of additional dlls that are needed for subreports.

Do you have VERIFY DATABASE ON OPEN set for the subreports?
Check the FILE --> REPORT OPTIONS on the subreports.
Also check the subreport linking to see if it is there.

Check if you have REIMPORT SUBREPORT checked on the subreport linking?

It sounds like either the subreport is trying to hit the database or the subreport doesn't exist on the nondevelopment environment.

mlmcc
0
 

Author Comment

by:nbandari
ID: 20809903
1)Do you have VERIFY DATABASE ON OPEN set for the subreports?
Check the FILE --> REPORT OPTIONS on the subreports.
I have VERIFYONEVERYPRINT set in my CRDesigner

I cant find  " VERIFY DATABASE ON OPEN " option in the report option, however, "Verify on first refresh" is set on main reports and subreports.

2)Also check the subreport linking to see if it is there.
The linking is ther

3) Check if you have REIMPORT SUBREPORT checked on the subreport linking
There is no such "REIMPORT SUBREPORT", however, there is a command with this name.

4)It sounds like either the subreport is trying to hit the database or the subreport doesn't exist on the nondevelopment environment.

I do not copy the report to nondevelopment environment.

nbandari

0
 

Author Comment

by:nbandari
ID: 20866577
I have found the problem. When I was creating my recordsets I was using a wrong attribute for fields that where varchar. For some reason this was working in development machines and not on test machines.
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 21339163
PAQed with points refunded (500)

Computer101
EE Admin
0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
In response to a need for security and privacy, and to continue fostering an environment members can turn to for support, solutions, and education, Experts Exchange has created anonymous question capabilities. This new feature is available to our Pr…
How to fix display issue, screen flickering issue when I plug in power cord to the machine. Before I start explaining the solution lets check out once the issue how it looks like after I connect the power cord. most of you also have faced this…
Suggested Courses

594 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question