on 09-28-2011 9:41 AM
Hi Experts,
I am using Subreport with the main report in Crystal Report Concept, I have two parameters same in both reports(Main and Subreport) and i give those parameters two times in different report, I want to give the parameters only once in main report so that it work for subreport also.
Kindly tell me, how can i get this solution
Regards
Rahul
Hi Rahul.....
I would suggest you to keep the parameters same in Main CR as well as Subreport also......
Regards,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rahul,
As i have mentioned already that i am working on Crystal Report , that has One Complete Report including Main report and one Subreport and both the reports have same parameters . I want to give parameters only once in main report so that it will work for subreport also.
Regards
Rahul
Hi,
Option 1:
Let's say in the main report, your parameter is called ?DateFrom
In the subreport, if you called in Pm-?DateFrom
You will notice that when you do the subreport link (right click on the subreport and select Change subreport link), select ?DateFrom, you will see that it will match ?DateFrom in main report to Pm-?DateFrom in subreport.
So, in the subreport, you use Pm-?DateFrom instead.
Option 2:
You can keep it the same name as you have done. You can link the subreport parameter with the main report parameter at Change subreport link as well.
Hope that make sense.
Hi,
I have two parameters @Docnum and @Cardcode which are same in both Main and Subreport, I am giving parameters two times in Main and Subreport, but i want to give only once in Main report and no need to give again for Subreport that will automatically work for Subreport.
how can i do this tell me the solution.
Regards
Rahul
Hi,
Im confused with your statement? When creating a subreport, it must be link to the main report unless
your sub report is independent.
Example :
Main Report - Parameter use (@DocNum,@CardCode)
Sub Report - Parameter use (?@DocNum,?@CardCode)
In dealing with subreport you must manually link which parameter from Main Report.
THanks.
Clint
Hi,
Please try this:-
1. Go to main design view in your crystal report.
2. Then do right click on the sub-report box.
3. Choose Change Subreport links.. option.
4. From Report fields choose your docnum parameter and press the right arrow key.
5. Then goto Subreport parameter field to use dropdownbox.
6. There will be three options :-
(a) ?Pm - ?docnum
(b) Parameter fields
(c) ?docnum
7. Choose (c) i.e. ?docnum
8. Now choose again from Report fields choose cardcode your second parameter and press the right arrow key.
9. Then goto Subreport parameter field to use dropdownbox.
10. There will be three options :-
(a) ?Pm - ?cardcode
(b) Parameter fields
(c) ?cardcode
11. Choose (c) i.e. ?cardcode
12. Finally choose OK.
Its done.
Regards
ARYA
Hi Arya,
I have tried your solution and followed all the steps but its not working , situation is still same again i am giving these two parameters two times First time in Main report then in Subreport.
I want the Solution so that i give the parameter's value only once in main report and it should work automatically for subreport.
Regards
Rahul
User | Count |
---|---|
107 | |
12 | |
11 | |
6 | |
5 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.