Compare a field from main report against a field from a subreport on CRYSTAL REPORT
Compare a field from main report against a field from a subreport on CRYSTAL REPORT
(OP)
I was wondering if there is a way for comparing a field from the main report against the a field from a subreport.
My main report is pointing to the current month data and the same report is pointing to the previous month data in the sub report.
I need to do something like:
IF SubReportStatus(previous month) = '1-30 days' AND MainReportStatus(Current month) = '31-60 days' THEN "Worse" ELSE IF
IF SubReportStatus(previous month) = '61-90 days' AND MainReportStatus(Current month) = '91+ days' THEN "Worse"
etc etc.
It would be really helpful and really appreciated to know if there's a way this can be done.
Many Thanks
My main report is pointing to the current month data and the same report is pointing to the previous month data in the sub report.
I need to do something like:
IF SubReportStatus(previous month) = '1-30 days' AND MainReportStatus(Current month) = '31-60 days' THEN "Worse" ELSE IF
IF SubReportStatus(previous month) = '61-90 days' AND MainReportStatus(Current month) = '91+ days' THEN "Worse"
etc etc.
It would be really helpful and really appreciated to know if there's a way this can be done.
Many Thanks
RE: Compare a field from main report against a field from a subreport on CRYSTAL REPORT
Or you can pass information from the main report into the subreport using a subreport link.
view, export, burst, email, and schedule Crystal Reports.
www.MilletSoftware.com
RE: Compare a field from main report against a field from a subreport on CRYSTAL REPORT
How would I go on about doing that?
I have tried a few ways, but what sort of shared variable and what would the steps be.
I want to be able to achieve the below and the outcome comes on the current month (main report):
IF SubReportStatus(previous month) = '1-30 days' AND MainReportStatus(Current month) = '31-60 days' THEN "Worse" ELSE IF
IF SubReportStatus(previous month) = '61-90 days' AND MainReportStatus(Current month) = '91+ days' THEN "Worse"
RE: Compare a field from main report against a field from a subreport on CRYSTAL REPORT
2) in the main report, somewhere after the placement of the subreport, compare the shared variable to the main report value
Macola Software Veteran and SAP Business One Consultant on Training Wheels
Check out our Macola tools:
www.gainfocus.biz/exceladdin.html
RE: Compare a field from main report against a field from a subreport on CRYSTAL REPORT
The field's I am trying to compare are text fields.
Can you please provide an example as to how I can declare this please?
I tried a few different ways but non worked.
Thanks
RE: Compare a field from main report against a field from a subreport on CRYSTAL REPORT
Shared Stringvar MyVar:={MySubreportField}
In the main report:
If Shared Stringvar MyVar<>{MyMainReportField} then.....
Macola Software Veteran and SAP Business One Consultant on Training Wheels
Check out our Macola tools:
www.gainfocus.biz/exceladdin.html