function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
mgodseymgodsey 

Trying to create a URL in a visualforce page to a dynamically filtered report

Hello.

 

Using http://buttonclickadmin.com/monday-am-admin-take-dynamically-filtered-reports-up-a-notch/ as a guide, I created a visualforce page and entered the HTML that creates the link to the filtered report. However, the example in the video is for the Account, and I need to have my report filtered based on a custom object ID. When I click on the link the report opens, but there is no filter. I'm using the HTML below, and I've been able to isolate that the issue is the pc0=INSERTION_ORDER_ID. For some reason I cannot get the correct naming convention for my custom object's ID, so no filter is created. Is there a way for me to look up exactly what it should be? The object name is Insertion_Order.

 

<p>

<a href="/00OQ0000000YNyo?pc0=INSERTION_ORDER_ID&pn0=eq&pv0={!LEFT(Insertion_Order__c.ID,15)}" target="_blank">EUR QA Report"</a>"

</p>

<p>

 

Thanks!

dash27dash27

<a href="/00OQ0000000YNyo?pc0=INSERTION_ORDER_ID&pn0=eq&pv0={!LEFT(Insertion_Order__c.ID,15)}" target="_blank">EUR QA Report"</a>

 

Should it be 'INSERTION_ORDER_ID__c'?

mgodseymgodsey

No, unfortunately that isn't working either. I just tried:

 

INSERTION_ORDER_ID__c

Insertion_Order_ID__c

Insertion_Order_Id__c

 

and none of them have worked. I'm stumped!

Pierre BARBIERPierre BARBIER

Hi, don't know if it has been answered elsewhere but here is the answer sopeople will know...

 

you should use Insertion_Order__r.id in your LEFT(... code.

 

<a href="/00OQ0000000YNyo?pc0=INSERTION_ORDER__R.ID&pn0=eq&pv0={!LEFT(Insertion_Order__r.ID,15)}" target="_blank">EUR QA Report"</a>