SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Report - SubReport


Report - SubReport

Author
Message
sharonsql2013
sharonsql2013
Ten Centuries
Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)

Group: General Forum Members
Points: 1260 Visits: 1265
I have two reports that Point to the same Sub Report.
On The Sub Report I have a text that says : Return to Main Page.
But I don't know How to return to respective main report since the sub report is the same.

Main Report FileName : Owner
Main Report : Application
SubReport : Details.

So, Under Details Report ,text says "Return to Main Page".
What should I have in Actions so that it points to respective Main Report.
P.S : Main Reports dont have any parameters.
happycat59
happycat59
SSCrazy Eights
SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)

Group: General Forum Members
Points: 8531 Visits: 3281
sharonsql2013 (4/25/2014)
I have two reports that Point to the same Sub Report.
On The Sub Report I have a text that says : Return to Main Page.
But I don't know How to return to respective main report since the sub report is the same.

Main Report FileName : Owner
Main Report : Application
SubReport : Details.

So, Under Details Report ,text says "Return to Main Page".
What should I have in Actions so that it points to respective Main Report.
P.S : Main Reports dont have any parameters.



How about adding a parameter to the subreport which is the name of the "Main Page" report.
In the action in the main reports, the value of the new parameter is the name of the relevant main report.
In the action in the subreport, use an expression in the "specify a report" box. For the expression, use the value from the new parameter



sharonsql2013
sharonsql2013
Ten Centuries
Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)

Group: General Forum Members
Points: 1260 Visits: 1265
Yes, But there are two separate Main reports.
So, In actions If I pass the report name as X it will work fine. But when I want to go to y Report , x report is already listed.... so y will not open up.
happycat59
happycat59
SSCrazy Eights
SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)SSCrazy Eights (8.5K reputation)

Group: General Forum Members
Points: 8531 Visits: 3281
In the subreport - create a new parameter. It will be contain the name of the main report that you want to call from the action on "Return to Main Page". In the action for that text box, do not type a value. Instead click on the "fx" next to the "specify a report" drop down. For the expression, you use the value of the new parameter.

In each of the main reports, in the action that calls the sub report, add a parameter (the same name as you specified for the new parameter in the sub report. The value of the parameter is the name of the report you are editing.



Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search