Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Get Link field value in a subreport.

Status
Not open for further replies.

Neo21

Programmer
Mar 25, 2002
14
IN

I am using a subreport to show details of a record.

I could set the datasource for the subreport which is using .ttx files, but my requirement is that i need know the mapping field value.

Out of the many records i display, i need to know the record on which user clicked( i.e drill on subreport) to view its details( the details are shown in subreport).

Actually this could be achived by linking the field(usually unique field) in main report to a field in subreport. But as i mentioned above, my requirement is to know the value of that field.


Thanks.

 
Link the field as normal, this will create a parameter in the subreport. Then delete the parameter from the selection formula in the subreport. The parameter will contain the value you need. Andrew Baines
Chase International
 
Thanks for the reply Andrew..

I tried that, but seems the parameter doesn't hold any value once the its removed from the RecordSelectionFormula.
And even if it is in RecordSelectionFormula the parameter value is having no value not only in DrillOnSubreport but also in DownloadFinished event.

Bascially i want to get that linking value in VB.. so that i can do some processing. Once i get that value, subreport is of no use to me.. so i want to supress it from displaying by setting

useDefault=False

Incase if there is any other way to know on what item did the user click, that will solve my problem too..

please reply...

Thanks..
 
I'm having a similar problem... I pass a string from VB to CR like this:

CrystalReport1.Formulas(0) = "UID= '" & mvAccountID & "'"

Then in the main report, I can print that string, so I know it's getting in there, but when I link the subreport (including record selection), the subreport is blank.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top