Losing CRM Context on Reports that navigate to other reports in CRM 4
-
16 พฤศจิกายน 2551 21:15
Hi
I've developed a report for CRM that has a link that allows you to navigate to another report. This works fine, so you can click on the link and it renders the next report.
However, when I render the second report the CRM drill through links in the second report are lost. Ie I can't click on a field value in the second report and get it to open a CRM screen. I see my tool tip that tells me I can click on it but don't get the little finger indicating a hyperlink and hence can't click on it.
However if I run the second report by itself the hyperlink drill through works fine.
Any idea on how to keep the second report to retain its CRM context when run from a hyperlink?
Cheers
Simon
ตอบทั้งหมด
-
17 พฤศจิกายน 2551 7:17ผู้ดูแล
How are you doing your drillthrough. If you are using any kind of javascript, it will not work in the CRM report viewer, but will work when viewed off of the report server.
Best way to do this:
1. define the CRM_URL parameter in your parent report
http://technet.microsoft.com/en-us/library/aa681484.aspx
2. Pass this parameter across to a CRM_URL parameter in your child report
3. The drillthroughs will work, and will be contextual to whatever client the users use (web, outlook, online, offline, ifd, etc).
-
17 พฤศจิกายน 2551 9:58
Thanks for your reply.
My code is using the suggested method on the link you provided. The only difference is that I use a dynamic look up for the entity code. This is because my report needs to work on multiple instances where the entity object type code may vary.
Here is my code:
=IIF(IsNothing(Parameters!CRM_URL.Value),Nothing,Parameters!CRM_URL.Value & "?ID={"&Fields!e4_employeeworksitepositionid.Value.ToString()&"}&OTC="&FIRST(Fields!ObjectTypeCode.Value, "ds_EmployeeWorksitePositionOTC"))
The strange this thing is the drill through does work when the report is run directly from CRM. Its only when the report is rendered from a link in another report that it doesn't work.
Cheers
-
17 พฤศจิกายน 2551 12:00ผู้ดูแล
when you run the report directly from CRM, the CRM_URL parameter is populated, when run from a link in another report, the CRM hidden parameters aren't used.
That's why you want to create the CRM_URL parameter in the report that is linking to this report, then in the hyperlink definition when you jump to report, hit the parameter button and link the crm_URL parameter from report 1 to the crm_URL parameter for report 2.