cancel
Showing results for 
Search instead for 
Did you mean: 

Prompted for parameter that should be passed to subreport in CR for VS2008

Former Member
0 Kudos

Reports created in CR10 were used with VS2003. Now I opened the project in VS2008. All reports run well exept reports with subreports.I have a prompt to enter a parameter that should be passed to subreport from main report. The link between main report and subreport is correct and works VS 2003, but not in VS2008. Can anybody help me how to correct it?

Edited by: Marina Yepifantseva on Jun 10, 2008 7:13 PM

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

You can try opening the reports from VS2008 and use the Set Datasource Location by right clicking on the Database Fields inside Field Explorer Window. Remap the fields of the report and try to preview the report.

Please note that the links between the tables must be maintained, in case of multiple tables.

This should upgrade the reports.

Former Member
0 Kudos

Thank you for the reply! I remaped stored procedures that used by main report and subreport, but this did not help me!!!!! The problem is still exists. Maybe I was not really clear, when I was describing it. Let me to start over.

I have reports created in CR10 and used in VS2003 successfully for years. All reports (main and subreports) are using stored procedures as datasources. If I open a report in VS2003 everything is fine as usually. If I open a report (which has a subreport(s)) in VS2008 the CR is prompting to provide a single value for the parameter which is used in subreport link, but normally (inVS2003) I never been asked. I do not understand why the parameter is not passing to subreport from main report during only at runtime. If I testing the report itself in CR10-there no problem, parameter passing.

Former Member
0 Kudos

VS2008 is not compatible with CR10 due to which I thought that updating the reports might help us.

I tried a simple report with a subreport in it having parameters in it in CR10 and tried it in VS2008. I could see the report properly.

If it is with one report I would suggest you to try with a simple new report. Otherewise you can try passing the parameter through code for the subreport and give it a try.

Hope it helps.

Regards,

AG.

Former Member
0 Kudos

Thank you for the reply AG!

Yesterday I did a test, I deleted a subreport from the report and there no problem to view it. So I got an idea to pass parameters thruthg the source code and today I got you reply with the same advise.

Do you have an experience with it? Can you help me with it, please?

Thank you again!

Marina

Edited by: Marina Yepifantseva on Jun 11, 2008 4:03 PM

Former Member
0 Kudos

The ReportDocument object has got a method SetParameterValue() that can be used to pass parameters to the reports.

e.g:

ReportDocumentObject.SetParameterValue("ParameterName","Value");

Hope it helps !

Answers (2)

Answers (2)

Former Member
0 Kudos

not really answered. Looks like nobody use VS2008 yet.

Former Member
0 Kudos

I had the exact same issue, using CR XI, and also CR for VS 2005. The problem seems to be fixed with CR VS2005 SP1, for Visual Studio CR.

Look up under Business Objects Downloads: Crystal Reports > .NET > Hot Fixes

Files:

CRRedist2005_x86.msi

crvs05sp1.exe

Then open the report again, and re-save it.

This has fixed the problem for me.

Good luck!

Former Member
0 Kudos

I just wondering, why you suggesting to me to use CRREDIST2005_X86.MSI file? It is a malware!

http://www.prevx.com/filenames/X1684642987566289052-0/CRREDIST2005_X86.MSI.html

Former Member
0 Kudos

The review you linked shows that it "has not yet been classified as safe", but does not have any specific proof that it is unsafe, either. This is a Crystal fix file from the Business Objects hot fix list. If you don't trust it, then find a different answer. It worked ok for me.

former_member183750
Active Contributor
0 Kudos

Please note that the file is sitting on your computer right now - it was installed by the CR install here:

c:\program files\microsoft visual studio 8\sdk\v2.0\bootstrapper\packages\crystal reports\CRRedist2005_x86.msi

So, I'm not sure how this became tagged as malware, but the one on your computer is most certainly safe.

former_member200290
Contributor
0 Kudos

This file is not malware, it is our redistributable MSI for Crystal Reports for Visual Studio 2005.

I will be looking into why this is being incorrectly reported as malware.

Trevor.

Former Member
0 Kudos

Thank you for your quick response!

Before I will use Hot fixes, I'm wondering, will this works with CR10 for VS2008?

Thanks

former_member183750
Active Contributor
0 Kudos

Yes it will. That file essentially contains all the Crystal Reports files on your computer right now, plus a bunch of directives re. registration of COM dlls, GAC and location to install the files to.

Ludek

former_member183750
Active Contributor
0 Kudos

oops. Somenone just pointed out I goofed. THe 2005 file is only for CR 10.2 which shipped with .NET 2005. Sorry for the confusion.

Former Member
0 Kudos

Well I am also confused a bit, with all the numbers, and would like to tell you that CR10 product is not compatible with VS2008. The only 2 products that is compatible with VS2008 are:

1) CR that comes with VS2008

2) CR2008 with SP0.

Hope it helps!

AG.

former_member183750
Active Contributor
0 Kudos

Marina, apologies for the confusion. A G is correct.

Former Member
0 Kudos

Yes, this correct about VS and CR versions. We have CR10 and recently upgraded to VS2008 from VS 2003. CR10 is not compatibles with new version of studio. There is an interesting detail about sub reports we have. Sub reports which do not used stored procedures to load fields are fine, sub reports with stored procedures, during run time (Crystal Reports viewer) prompted to enter a parameter which is generated during the runtime. To solve this problem, I deleted sub reports which gives us this kind of problem from the main report and made them as main reports, too. Now they called after the main report opens. The design of these reports allowed me to do it. Because we do not plan to have a newer version of Crystal Report, instead we have plan to switch to SQL Reports Designer, this solution is fine for us.

Than you all for the advices!