?
Solved

Crystal Subreport - Passing Parameters

Posted on 2008-06-10
4
Medium Priority
?
589 Views
Last Modified: 2011-10-19
Good Day
Experts:

I am having a bit of trouble with a Crystal Report that contains a Subreport.  That Subreport gets it's data from a Stored Procedure which takes a parameter supplied by the main report.  It is apparent that I need additional coding in my VB.net application as the report works fine from the Crystal Editor.  I have attached my code in a file that shows what I am doing so far.  I am changing the connection information at the Subreport level...so I think I am close here.  Just not sure how to pass the parameter that the S/P requires.

I have tried searching the net for assistance but have not found a conclusive solution.  

Thanks,
jimbo00000
SubReport.doc
0
Comment
Question by:Jimbo99999
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 101

Assisted Solution

by:mlmcc
mlmcc earned 400 total points
ID: 21752536
I believe the code you are using to pass parameters to the main report should work but you need to do it with the subreport object.

mlmcc
0
 

Author Comment

by:Jimbo99999
ID: 21752827
We found the following ServicePack --> CrystalReportForVisualStudio2005_SP1

One of the items that was a fix involved the ParameterFieldDefinition.IsLinked property which returns a boolean indicating whether the parameter field is the link between a SubReport and the Main report.  This property was always returning false.

My Report is now working as designed.

Thanks,
jimbo99999

0
 
LVL 1

Assisted Solution

by:nismoto
nismoto earned 400 total points
ID: 21752920
Have you tried to set the sub-report parameters in the main report? Open the report in the editor (VS or Crystal), right-click on the sub-report and select "Change Subreport Links..." (see screenshot).
screenshot.png
0
 

Accepted Solution

by:
Jimbo99999 earned 0 total points
ID: 21824357
Thanks for your replies.  I had to apply a hotfix with a couple new dll's.  

jimbo99999
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

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

Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
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 …
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

770 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